@fougere/transport-http
The call contract on the wire, in JSON-RPC 2.0 (server + client).
Entries: @fougere/transport-http · @fougere/transport-http/receive · @fougere/transport-http/client
What you import
| name | |
|---|---|
createHttpTransport | |
frameCall | Frame a call as a JSON-RPC request. |
unframeResponse | Unframe a JSON-RPC response — the result, or the revived FougereError thrown. |
handleRpc | A peer's call, through the app's cycle when the receiver holds one. |
pageDoor | The door a page calls through: its state is what the host resolved, and it may not write args. |
peerDoor | The door a process calls another through: verify establishes its state, and what it judged is not judged again. |
receive | |
maxFrameBytes | |
serve | |
PARSE_ERROR |
Types
TypeScript types only — they do not run. Import them with import type to type your own code: a variable, a parameter, an option object.
| name | |
|---|---|
ReceiveOptions | What a receiver does with the caller's envelope. |
RpcCall | One call, unframed. |
PageDoorOptions | What a host hands the door a page calls through. |
RunningReceiver | |
RpcResponse |