Skip to main content

install

Function install 

Source
pub fn install(cx: &mut JSContext)
Expand description

Install the router on the current thread’s runtime:

  • registers the SpiderMonkey promise-rejection tracker (idempotent — the callback lives on the runtime; re-installs overwrite with the same fn);
  • registers the bao_engine job-queue hooks (uncaught-exception routing + pending-rejection flush) so job_queue can call back without a bao_engine → bao_runtime dependency edge (same pattern as module_loader::set_job_queue_drain).