DeliveryControllerType
The object a delivery strategy returns for a single
listen()
subscription.
Think of it as a tiny pipe:
push
is the input (every raw message lands here),
deliver
from the
DeliveryStrategyContextType
is the output, and
dispose
is the cleanup.
Import
import { DeliveryControllerType } from "@hyper-fetch/sockets"
Source
Package
Preview
type DeliveryControllerType<Input,Extra> = {
dispose: () => void;
push: (message: DeliveryMessageType<Input, Extra>) => void;
}
Structure
DeliveryControllerType
| Name | Type | Description |
|---|---|---|
| dispose | | Called when the subscription ends (
|
| push | | Receives every raw message of the subscription. The strategy decides if and when to call
|
