Module specifier for the worker's setup module — a URL, or an
absolute path/specifier a worker can import().
It must export a setup function (as default or setup) returning
{ registry, units?, sources?, datasets? }. A module, not a value,
because a registry is functions and functions do not survive
structured clone.
OptionalReadonlysetupOptions
setupOptions?:unknown
Passed to the setup function, so one module can serve several pools.
OptionalReadonlysize
size?:number
Workers to start. Default: availableParallelism() - 1, min 1.
Module specifier for the worker's setup module — a
URL, or an absolute path/specifier a worker canimport().It must export a setup function (as
defaultorsetup) returning{ registry, units?, sources?, datasets? }. A module, not a value, because a registry is functions and functions do not survive structured clone.