[{"data":1,"prerenderedAt":244,"buildId":245},["ShallowReactive",2],{"index":3,"navigation":157},{"id":4,"title":5,"body":6,"description":149,"extension":150,"meta":151,"navigation":152,"path":153,"seo":154,"stem":155,"__hash__":156},"landing\u002Findex.md","oruntime",{"type":7,"value":8,"toc":142},"minimark",[9,12,16,19,22,53,58,95,99,127],[10,11,5],"h1",{"id":5},[13,14,15],"p",{},"Write code around the capabilities it needs, not around the runtime that executes it.",[13,17,18],{},"oruntime detects the current JavaScript environment and provides a typed,\nconsistent API for inspecting its capabilities, reading environment variables,\naccessing arguments, finding the current working directory, and using portable\nprimitives for Fetch, timers, and URLs.",[13,20,21],{},"Framework-agnostic and built on Web standards, the library lets you share the\nsame code across Node.js, Bun, Deno, Cloudflare Workers, and browsers without\nhiding the important differences between those environments.",[23,24,28,39,46],"u-page-grid",{"className":25},[26,27],"gap-3","mt-16",[29,30],"u-page-card",{"description":31,"icon":32,"title":33,"to":34,":spotlight":35,":ui":36,"className":37},"Install oruntime, detect your runtime, and use your first adapter.","i-lucide-rocket","Get started","\u002Fgetting-started","true","{\"leading\":\"h-38 flex items-start\"}",[38],"shadow-lg",[29,40],{"description":41,"icon":42,"title":43,"to":44,":spotlight":35,":ui":36,"className":45},"Learn how runtimes are identified and what each environment supports.","i-lucide-radar","Detection and capabilities","\u002Fcore-concepts\u002Fruntime-detection",[38],[29,47],{"description":48,"icon":49,"title":50,"to":51,":spotlight":35,":ui":36,"className":52},"Use a stable interface for runtime-specific information and operations.","i-lucide-plug","Runtime adapter","\u002Fcore-concepts\u002Fruntime-adapter",[38],[54,55,57],"h2",{"id":56},"runtime-features","Runtime features",[23,59,61,66,72,77,83,89],{"className":60},[26],[29,62],{"description":63,"icon":64,"title":65,"to":44},"Identify Node.js, Bun, Deno, workerd, and browsers.","i-lucide-scan-search","Detection",[29,67],{"description":68,"icon":69,"title":70,"to":71},"Check which APIs are available before using them.","i-lucide-list-checks","Capabilities","\u002Fcore-concepts\u002Fcapabilities",[29,73],{"description":74,"icon":75,"title":76,"to":51},"Read one variable or the complete environment.","i-lucide-square-terminal","Environment",[29,78],{"description":79,"icon":80,"title":81,"to":82},"Make requests and validate responses consistently.","i-lucide-cloud-download","Fetch","\u002Futilities\u002Ffetch",[29,84],{"description":85,"icon":86,"title":87,"to":88},"Wait or enforce a deadline with AbortSignal.","i-lucide-timer","Timers","\u002Futilities\u002Ftimers",[29,90],{"description":91,"icon":92,"title":93,"to":94},"Create, resolve, and enrich URLs with portable functions.","i-lucide-link","URL","\u002Futilities\u002Furl",[54,96,98],{"id":97},"what-the-library-supports","What the library supports",[100,101,102,106,109,112,115,118,121,124],"ul",{},[103,104,105],"li",{},"ordered runtime detection and runtime versions when available;",[103,107,108],{},"a typed description of the capabilities that are actually present;",[103,110,111],{},"a common interface for environment variables, arguments, and the current directory;",[103,113,114],{},"Fetch utilities with response validation and JSON or text readers;",[103,116,117],{},"abortable timers and explicit timeouts;",[103,119,120],{},"URL creation, resolution, and modification;",[103,122,123],{},"common errors with stable codes and preserved causes;",[103,125,126],{},"extension points for injecting globals in tests.",[128,129,133],"callout",{"color":130,"icon":131,"variant":132},"neutral","i-lucide-info","subtle",[13,134,135,136,141],{},"oruntime does not reimplement file systems, paths, HTTP or WebSocket servers,\ncryptography, or encoding. Those responsibilities remain with native APIs and\nspecialized libraries. See the ",[137,138,140],"a",{"href":139},"\u002Freference\u002Fscope","project scope"," to understand\nthese decisions.",{"title":143,"searchDepth":144,"depth":145,"links":146},"",1,2,[147,148],{"id":56,"depth":145,"text":57},{"id":97,"depth":145,"text":98},"A predictable compatibility layer for modern JavaScript runtimes.","md",{},false,"\u002F",{"title":5,"description":149},"index","YKzYYihvZBeXmldvJtkkD3uNgP4YaxtG-dyH8wDtvHk",[158,176,193,205,227],{"title":159,"path":34,"stem":160,"children":161,"icon":32},"Getting started","1.getting-started\u002F1.index",[162,164,168,172],{"title":163,"path":34,"stem":160},"Introduction",{"title":165,"path":166,"stem":167},"Installation","\u002Fgetting-started\u002Finstallation","1.getting-started\u002F2.installation",{"title":169,"path":170,"stem":171},"Quick start","\u002Fgetting-started\u002Fquick-start","1.getting-started\u002F3.quick-start",{"title":173,"path":174,"stem":175},"Runtime support","\u002Fgetting-started\u002Fruntime-support","1.getting-started\u002F4.runtime-support",{"title":177,"icon":178,"path":179,"stem":180,"children":181,"page":152},"Core concepts","i-lucide-box","\u002Fcore-concepts","2.core-concepts",[182,185,187,189],{"title":183,"path":44,"stem":184},"Runtime detection","2.core-concepts\u002F1.runtime-detection",{"title":50,"path":51,"stem":186},"2.core-concepts\u002F2.runtime-adapter",{"title":70,"path":71,"stem":188},"2.core-concepts\u002F3.capabilities",{"title":190,"path":191,"stem":192},"Error handling","\u002Fcore-concepts\u002Ferrors","2.core-concepts\u002F4.errors",{"title":194,"icon":195,"path":196,"stem":197,"children":198,"page":152},"Utilities","i-lucide-wrench","\u002Futilities","3.utilities",[199,201,203],{"title":81,"path":82,"stem":200},"3.utilities\u002F1.fetch",{"title":87,"path":88,"stem":202},"3.utilities\u002F2.timers",{"title":93,"path":94,"stem":204},"3.utilities\u002F3.url",{"title":206,"icon":207,"path":208,"stem":209,"children":210,"page":152},"Guides","i-lucide-graduation-cap","\u002Fguides","4.guides",[211,215,219,223],{"title":212,"path":213,"stem":214},"Deno permissions","\u002Fguides\u002Fdeno-permissions","4.guides\u002F1.deno-permissions",{"title":216,"path":217,"stem":218},"Conditional code","\u002Fguides\u002Fconditional-code","4.guides\u002F2.conditional-code",{"title":220,"path":221,"stem":222},"Testing multiple runtimes","\u002Fguides\u002Ftesting","4.guides\u002F3.testing",{"title":224,"path":225,"stem":226},"Frequently asked questions","\u002Fguides\u002Ffaq","4.guides\u002F4.faq",{"title":228,"icon":229,"path":230,"stem":231,"children":232,"page":152},"Reference","i-lucide-book-open","\u002Freference","5.reference",[233,237,240],{"title":234,"path":235,"stem":236},"API reference","\u002Freference\u002Fapi","5.reference\u002F1.api",{"title":238,"path":139,"stem":239},"Scope and design decisions","5.reference\u002F2.scope",{"title":241,"path":242,"stem":243},"Roadmap","\u002Freference\u002Froadmap","5.reference\u002F3.roadmap",1796297153906,"7c446e43-2e3e-4ee5-9931-1c6979897184"]