# Subscribable

> _Since v2.4.0_

Minimal Subscribable contract used by ServerSideDataSource.getRows when
an Observable-based data source is preferred over a `Promise`. Matches the
shape of RxJS `Observable` and the TC39 Observable proposal — any value that
exposes a `.subscribe(observer)` method returning an unsubscribable handle
works without a runtime dependency on RxJS.

The plugin subscribes once, expects exactly one `next` (the result), and
tears the subscription down on `complete`, `error`, or when the request is
superseded (`AbortSignal` fires) — which is what causes Angular `HttpClient`
to cancel the underlying XHR.

## Methods

### subscribe()

```ts
subscribe(observer: { next?: unknown; error?: unknown; complete?: unknown }): { unsubscribe: unknown }
```

#### Parameters

| Name | Type | Description |
| ---- | ---- | ----------- |
| `observer` | <code>&#123; next?: unknown; error?: unknown; complete?: unknown &#125;</code> |  |

***
