createPearApp
@totemsdk/pear / createPearApp
Function: createPearApp()
createPearApp(
config?):PearApp
Initialise the Pear runtime integration.
- Registers
runExitHandlerswithglobalThis.Pear.teardownonce (idempotent; safe to call on every app init). - Registers the
onUpdatehandler every time a non-null handler is provided — the handler is not guarded so it can be refreshed. - Safe to call in environments without
globalThis.Pear(Node.js, bare without Pear) — no-op for the Pear-specific parts.
Parameters
config?
PearAppConfig = {}