Skip to content

five-on-it / apps/server/src/rtc-host / RtcHostOptions

Interface: RtcHostOptions ​

Defined in: apps/server/src/rtc-host.ts:74

How the host runs.

Properties ​

log? ​

optional log?: (message) => void

Defined in: apps/server/src/rtc-host.ts:76

Parameters ​

message ​

string

Returns ​

void


now? ​

optional now?: () => number

Defined in: apps/server/src/rtc-host.ts:79

Returns ​

number


schedule? ​

optional schedule?: (run) => void

Defined in: apps/server/src/rtc-host.ts:81

Runs a batch's flush at the end of the turn (setImmediate; the tests flush by hand).

Parameters ​

run ​

() => void

Returns ​

void


settings ​

settings: RtcSettings

Defined in: apps/server/src/rtc-host.ts:75


spawn? ​

optional spawn?: (config) => WorkerLike

Defined in: apps/server/src/rtc-host.ts:78

Starts the worker (a Worker on rtc-worker; the tests give a fake).

Parameters ​

config ​

RtcWorkerConfig

Returns ​

WorkerLike