Skip to content

This site describes solve-engine as it is on main: 2.43.0, which npm does not have yet. npm installs 2.40.0, so a page may show an answer that version does not give yet.

WorkerRuntimeOptions

Defined in: packages/engine/src/worker/runtime.ts:61

Options a host bakes into its own worker entry: its custom packages, and its calendar backend.

optional calendar?: CalendarBackend;

Defined in: packages/engine/src/worker/runtime.ts:77

The calendar backend the worker’s engine computes dates with, and writes them out with, as the engine’s own calendar option. Defaults to the built-in Date backend. Baked in here for the same reason a package is: a backend is an object of functions and cannot be posted across the boundary, so the main side’s formatting settings never carry one.


optional packages?: IEnginePackage[];

Defined in: packages/engine/src/worker/runtime.ts:69

The packages available to register, defaulting to BUILTIN_PACKAGES. A host with its own package authors a worker entry that passes them here, then selects among them by name from the main side. This is how a function-carrying package reaches the worker: baked into its bundle, never posted across the boundary.