[{"data":1,"prerenderedAt":2085},["ShallowReactive",2],{"navigation_docs":3,"-extend-stream":533,"-extend-stream-surround":2080},[4,29,76,122,304,436,495],{"title":5,"path":6,"stem":7,"children":8,"page":28},"Start","\u002Fstart","1.start",[9,13,18,23],{"title":10,"path":11,"stem":12},"Introduction","\u002Fstart\u002Fintroduction","1.start\u002F1.introduction",{"title":14,"path":15,"stem":16,"icon":17},"Why start with evlog","\u002Fstart\u002Fwhy-evlog","1.start\u002F2.why-evlog","i-lucide-rocket",{"title":19,"path":20,"stem":21,"icon":22},"Installation","\u002Fstart\u002Finstallation","1.start\u002F3.installation","i-lucide-download",{"title":24,"path":25,"stem":26,"icon":27},"Quick Start","\u002Fstart\u002Fquick-start","1.start\u002F4.quick-start","i-lucide-zap",false,{"title":30,"path":31,"stem":32,"children":33,"page":28},"Learn","\u002Flearn","2.learn",[34,38,43,48,53,58,62,67,72],{"title":35,"path":36,"stem":37},"Learn evlog","\u002Flearn\u002Foverview","2.learn\u002F0.overview",{"title":39,"path":40,"stem":41,"icon":42},"Simple Logging","\u002Flearn\u002Fsimple-logging","2.learn\u002F1.simple-logging","i-lucide-terminal",{"title":44,"path":45,"stem":46,"icon":47},"Wide Events","\u002Flearn\u002Fwide-events","2.learn\u002F2.wide-events","i-lucide-layers",{"title":49,"path":50,"stem":51,"icon":52},"Structured Errors","\u002Flearn\u002Fstructured-errors","2.learn\u002F3.structured-errors","i-lucide-shield-alert",{"title":54,"path":55,"stem":56,"icon":57},"Lifecycle","\u002Flearn\u002Flifecycle","2.learn\u002F4.lifecycle","i-lucide-arrow-right-left",{"title":59,"path":60,"stem":61},"Sampling","\u002Flearn\u002Fsampling","2.learn\u002F5.sampling",{"title":63,"path":64,"stem":65,"icon":66},"Auto-Redaction","\u002Flearn\u002Fredaction","2.learn\u002F6.redaction","i-lucide-eye-off",{"title":68,"path":69,"stem":70,"icon":71},"Typed Fields","\u002Flearn\u002Ftyped-fields","2.learn\u002F7.typed-fields","i-simple-icons-typescript",{"title":73,"path":74,"stem":75},"Catalogs","\u002Flearn\u002Fcatalogs","2.learn\u002F8.catalogs",{"title":77,"path":78,"stem":79,"children":80,"page":28},"CLI","\u002Fcli","3.cli",[81,85,90,95,99,103,108,113,118],{"title":82,"path":83,"stem":84},"evlog CLI","\u002Fcli\u002Foverview","3.cli\u002F0.overview",{"title":86,"path":87,"stem":88,"icon":89},"init","\u002Fcli\u002Finit","3.cli\u002F1.init","i-lucide-wand-sparkles",{"title":91,"path":92,"stem":93,"icon":94},"map","\u002Fcli\u002Fmap","3.cli\u002F2.map","i-lucide-radar",{"title":96,"path":97,"stem":98},"Map rules","\u002Fcli\u002Frules","3.cli\u002F3.rules",{"title":100,"path":101,"stem":102},"Map scoring","\u002Fcli\u002Fscoring","3.cli\u002F4.scoring",{"title":104,"path":105,"stem":106,"icon":107},"CI","\u002Fcli\u002Fci","3.cli\u002F5.ci","i-lucide-git-pull-request",{"title":109,"path":110,"stem":111,"icon":112},"doctor","\u002Fcli\u002Fdoctor","3.cli\u002F6.doctor","i-lucide-stethoscope",{"title":114,"path":115,"stem":116,"icon":117},"telemetry","\u002Fcli\u002Ftelemetry","3.cli\u002F7.telemetry","i-lucide-bar-chart-3",{"title":119,"path":120,"stem":121},"evlog agents","\u002Fcli\u002Fagents","3.cli\u002F8.agents",{"title":123,"path":124,"stem":125,"children":126,"page":28},"Integrate","\u002Fintegrate","4.integrate",[127,132,216],{"title":128,"path":129,"stem":130,"icon":131},"Overview","\u002Fintegrate\u002Foverview","4.integrate\u002F0.overview","i-lucide-plug",{"title":133,"path":134,"stem":135,"children":136,"page":28},"Adapters","\u002Fintegrate\u002Fadapters","4.integrate\u002Fadapters",[137,141,171,196],{"title":128,"path":138,"stem":139,"icon":140},"\u002Fintegrate\u002Fadapters\u002Foverview","4.integrate\u002Fadapters\u002F01.overview","i-lucide-list",{"title":142,"path":143,"stem":144,"children":145,"page":28},"Cloud","\u002Fintegrate\u002Fadapters\u002Fcloud","4.integrate\u002Fadapters\u002Fcloud",[146,151,156,161,166],{"title":147,"path":148,"stem":149,"icon":150},"Axiom","\u002Fintegrate\u002Fadapters\u002Fcloud\u002Faxiom","4.integrate\u002Fadapters\u002Fcloud\u002F01.axiom","i-custom-axiom",{"title":152,"path":153,"stem":154,"icon":155},"PostHog","\u002Fintegrate\u002Fadapters\u002Fcloud\u002Fposthog","4.integrate\u002Fadapters\u002Fcloud\u002F02.posthog","i-simple-icons-posthog",{"title":157,"path":158,"stem":159,"icon":160},"Sentry","\u002Fintegrate\u002Fadapters\u002Fcloud\u002Fsentry","4.integrate\u002Fadapters\u002Fcloud\u002F03.sentry","i-simple-icons-sentry",{"title":162,"path":163,"stem":164,"icon":165},"Better Stack","\u002Fintegrate\u002Fadapters\u002Fcloud\u002Fbetter-stack","4.integrate\u002Fadapters\u002Fcloud\u002F04.better-stack","i-simple-icons-betterstack",{"title":167,"path":168,"stem":169,"icon":170},"Datadog","\u002Fintegrate\u002Fadapters\u002Fcloud\u002Fdatadog","4.integrate\u002Fadapters\u002Fcloud\u002F05.datadog","i-simple-icons-datadog",{"title":172,"path":173,"stem":174,"children":175,"page":28},"Cloud or Self-Hosted","\u002Fintegrate\u002Fadapters\u002Fhybrid","4.integrate\u002Fadapters\u002Fhybrid",[176,181,186,191],{"title":177,"path":178,"stem":179,"icon":180},"Grafana Loki","\u002Fintegrate\u002Fadapters\u002Fhybrid\u002Floki","4.integrate\u002Fadapters\u002Fhybrid\u002F01.loki","i-simple-icons-grafana",{"title":182,"path":183,"stem":184,"icon":185},"ClickHouse","\u002Fintegrate\u002Fadapters\u002Fhybrid\u002Fclickhouse","4.integrate\u002Fadapters\u002Fhybrid\u002F02.clickhouse","i-simple-icons-clickhouse",{"title":187,"path":188,"stem":189,"icon":190},"OTLP","\u002Fintegrate\u002Fadapters\u002Fhybrid\u002Fotlp","4.integrate\u002Fadapters\u002Fhybrid\u002F03.otlp","i-simple-icons-opentelemetry",{"title":192,"path":193,"stem":194,"icon":195},"HyperDX","\u002Fintegrate\u002Fadapters\u002Fhybrid\u002Fhyperdx","4.integrate\u002Fadapters\u002Fhybrid\u002F04.hyperdx","i-custom-hyperdx",{"title":197,"path":198,"stem":199,"children":200,"page":28},"Self-Hosted","\u002Fintegrate\u002Fadapters\u002Fself-hosted","4.integrate\u002Fadapters\u002Fself-hosted",[201,206,211],{"title":202,"path":203,"stem":204,"icon":205},"File System","\u002Fintegrate\u002Fadapters\u002Fself-hosted\u002Ffs","4.integrate\u002Fadapters\u002Fself-hosted\u002F01.fs","i-lucide-hard-drive",{"title":207,"path":208,"stem":209,"icon":210},"NuxtHub","\u002Fintegrate\u002Fadapters\u002Fself-hosted\u002Fnuxthub","4.integrate\u002Fadapters\u002Fself-hosted\u002F02.nuxthub","i-simple-icons-nuxt",{"title":212,"path":213,"stem":214,"icon":215},"Memory","\u002Fintegrate\u002Fadapters\u002Fself-hosted\u002Fmemory","4.integrate\u002Fadapters\u002Fself-hosted\u002F03.memory","i-lucide-cpu",{"title":217,"path":218,"stem":219,"children":220,"page":28},"Frameworks","\u002Fintegrate\u002Fframeworks","4.integrate\u002Fframeworks",[221,225,230,235,240,245,250,255,260,265,270,275,280,285,289,294,299],{"title":128,"path":222,"stem":223,"icon":224},"\u002Fintegrate\u002Fframeworks\u002Foverview","4.integrate\u002Fframeworks\u002F00.overview","i-lucide-layout-grid",{"title":226,"path":227,"stem":228,"icon":229},"Nuxt","\u002Fintegrate\u002Fframeworks\u002Fnuxt","4.integrate\u002Fframeworks\u002F01.nuxt","i-simple-icons-nuxtdotjs",{"title":231,"path":232,"stem":233,"icon":234},"Next.js","\u002Fintegrate\u002Fframeworks\u002Fnextjs","4.integrate\u002Fframeworks\u002F02.nextjs","i-simple-icons-nextdotjs",{"title":236,"path":237,"stem":238,"icon":239},"SvelteKit","\u002Fintegrate\u002Fframeworks\u002Fsveltekit","4.integrate\u002Fframeworks\u002F03.sveltekit","i-simple-icons-svelte",{"title":241,"path":242,"stem":243,"icon":244},"Nitro","\u002Fintegrate\u002Fframeworks\u002Fnitro","4.integrate\u002Fframeworks\u002F04.nitro","i-custom-nitro",{"title":246,"path":247,"stem":248,"icon":249},"TanStack Start","\u002Fintegrate\u002Fframeworks\u002Ftanstack-start","4.integrate\u002Fframeworks\u002F05.tanstack-start","i-custom-tanstack",{"title":251,"path":252,"stem":253,"icon":254},"NestJS","\u002Fintegrate\u002Fframeworks\u002Fnestjs","4.integrate\u002Fframeworks\u002F06.nestjs","i-simple-icons-nestjs",{"title":256,"path":257,"stem":258,"icon":259},"Express","\u002Fintegrate\u002Fframeworks\u002Fexpress","4.integrate\u002Fframeworks\u002F07.express","i-simple-icons-express",{"title":261,"path":262,"stem":263,"icon":264},"Hono","\u002Fintegrate\u002Fframeworks\u002Fhono","4.integrate\u002Fframeworks\u002F08.hono","i-simple-icons-hono",{"title":266,"path":267,"stem":268,"icon":269},"Fastify","\u002Fintegrate\u002Fframeworks\u002Ffastify","4.integrate\u002Fframeworks\u002F09.fastify","i-simple-icons-fastify",{"title":271,"path":272,"stem":273,"icon":274},"Elysia","\u002Fintegrate\u002Fframeworks\u002Felysia","4.integrate\u002Fframeworks\u002F10.elysia","i-custom-elysia",{"title":276,"path":277,"stem":278,"icon":279},"React Router","\u002Fintegrate\u002Fframeworks\u002Freact-router","4.integrate\u002Fframeworks\u002F11.react-router","i-custom-reactrouter",{"title":281,"path":282,"stem":283,"icon":284},"Cloudflare Workers","\u002Fintegrate\u002Fframeworks\u002Fcloudflare-workers","4.integrate\u002Fframeworks\u002F12.cloudflare-workers","i-simple-icons-cloudflare",{"title":286,"path":287,"stem":288,"icon":71},"Standalone","\u002Fintegrate\u002Fframeworks\u002Fstandalone","4.integrate\u002Fframeworks\u002F13.standalone",{"title":290,"path":291,"stem":292,"icon":293},"Astro","\u002Fintegrate\u002Fframeworks\u002Fastro","4.integrate\u002Fframeworks\u002F14.astro","i-simple-icons-astro",{"title":295,"path":296,"stem":297,"icon":298},"oRPC","\u002Fintegrate\u002Fframeworks\u002Forpc","4.integrate\u002Fframeworks\u002F15.orpc","i-lucide-network",{"title":300,"path":301,"stem":302,"icon":303},"AWS Lambda","\u002Fintegrate\u002Fframeworks\u002Faws-lambda","4.integrate\u002Fframeworks\u002F16.aws-lambda","i-custom-lambda",{"title":305,"path":306,"stem":307,"children":308,"page":28},"Use Cases","\u002Fuse-cases","5.use-cases",[309,312,317,346,374,407,427,432],{"title":305,"path":310,"stem":311},"\u002Fuse-cases\u002Foverview","5.use-cases\u002F0.overview",{"title":313,"path":314,"stem":315,"icon":316},"Client Logging","\u002Fuse-cases\u002Fclient-logging","5.use-cases\u002F1.client-logging","i-lucide-monitor",{"title":318,"icon":319,"path":320,"stem":321,"children":322,"page":28},"AI SDK","i-simple-icons-vercel","\u002Fuse-cases\u002Fai-sdk","5.use-cases\u002F2.ai-sdk",[323,326,331,336,341],{"title":128,"path":324,"stem":325,"icon":140},"\u002Fuse-cases\u002Fai-sdk\u002Foverview","5.use-cases\u002F2.ai-sdk\u002F01.overview",{"title":327,"path":328,"stem":329,"icon":330},"Usage","\u002Fuse-cases\u002Fai-sdk\u002Fusage","5.use-cases\u002F2.ai-sdk\u002F02.usage","i-lucide-code",{"title":332,"path":333,"stem":334,"icon":335},"Options","\u002Fuse-cases\u002Fai-sdk\u002Foptions","5.use-cases\u002F2.ai-sdk\u002F03.options","i-lucide-sliders",{"title":337,"path":338,"stem":339,"icon":340},"Metadata","\u002Fuse-cases\u002Fai-sdk\u002Fmetadata","5.use-cases\u002F2.ai-sdk\u002F04.metadata","i-lucide-database",{"title":342,"path":343,"stem":344,"icon":345},"Telemetry","\u002Fuse-cases\u002Fai-sdk\u002Ftelemetry","5.use-cases\u002F2.ai-sdk\u002F05.telemetry","i-lucide-activity",{"title":347,"icon":348,"path":349,"stem":350,"children":351,"page":28},"Better Auth","i-simple-icons-betterauth","\u002Fuse-cases\u002Fbetter-auth","5.use-cases\u002F3.better-auth",[352,355,360,365,369],{"title":128,"path":353,"stem":354,"icon":140},"\u002Fuse-cases\u002Fbetter-auth\u002Foverview","5.use-cases\u002F3.better-auth\u002F01.overview",{"title":356,"path":357,"stem":358,"icon":359},"Identify User","\u002Fuse-cases\u002Fbetter-auth\u002Fidentify-user","5.use-cases\u002F3.better-auth\u002F02.identify-user","i-lucide-user-check",{"title":361,"path":362,"stem":363,"icon":364},"Middleware","\u002Fuse-cases\u002Fbetter-auth\u002Fmiddleware","5.use-cases\u002F3.better-auth\u002F03.middleware","i-lucide-shield",{"title":366,"path":367,"stem":368,"icon":316},"Client Sync","\u002Fuse-cases\u002Fbetter-auth\u002Fclient-sync","5.use-cases\u002F3.better-auth\u002F04.client-sync",{"title":370,"path":371,"stem":372,"icon":373},"Performance","\u002Fuse-cases\u002Fbetter-auth\u002Fperformance","5.use-cases\u002F3.better-auth\u002F05.performance","i-lucide-gauge",{"title":375,"icon":376,"path":377,"stem":378,"children":379,"page":28},"Audit Logs","i-lucide-shield-check","\u002Fuse-cases\u002Faudit","5.use-cases\u002F4.audit",[380,383,388,393,398,402],{"title":128,"path":381,"stem":382,"icon":140},"\u002Fuse-cases\u002Faudit\u002Foverview","5.use-cases\u002F4.audit\u002F01.overview",{"title":384,"path":385,"stem":386,"icon":387},"Schema","\u002Fuse-cases\u002Faudit\u002Fschema","5.use-cases\u002F4.audit\u002F02.schema","i-lucide-file-text",{"title":389,"path":390,"stem":391,"icon":392},"Recording","\u002Fuse-cases\u002Faudit\u002Frecording","5.use-cases\u002F4.audit\u002F03.recording","i-lucide-pen-line",{"title":394,"path":395,"stem":396,"icon":397},"Drains","\u002Fuse-cases\u002Faudit\u002Fpipeline","5.use-cases\u002F4.audit\u002F04.pipeline","i-lucide-link",{"title":399,"path":400,"stem":401,"icon":376},"Compliance","\u002Fuse-cases\u002Faudit\u002Fcompliance","5.use-cases\u002F4.audit\u002F05.compliance",{"title":403,"path":404,"stem":405,"icon":406},"Recipes","\u002Fuse-cases\u002Faudit\u002Frecipes","5.use-cases\u002F4.audit\u002F06.recipes","i-lucide-book-open",{"title":342,"icon":373,"path":408,"stem":409,"children":410,"page":28},"\u002Fuse-cases\u002Ftelemetry","5.use-cases\u002F4.telemetry",[411,414,419,423],{"title":128,"path":412,"stem":413,"icon":140},"\u002Fuse-cases\u002Ftelemetry\u002Foverview","5.use-cases\u002F4.telemetry\u002F01.overview",{"title":415,"path":416,"stem":417,"icon":418},"Setup","\u002Fuse-cases\u002Ftelemetry\u002Fsetup","5.use-cases\u002F4.telemetry\u002F02.setup","i-lucide-wrench",{"title":420,"path":421,"stem":422},"Telemetry Ingest","\u002Fuse-cases\u002Ftelemetry\u002Fingest","5.use-cases\u002F4.telemetry\u002F03.ingest",{"title":424,"path":425,"stem":426,"icon":406},"Reference","\u002Fuse-cases\u002Ftelemetry\u002Freference","5.use-cases\u002F4.telemetry\u002F04.reference",{"title":428,"path":429,"stem":430,"icon":431},"Enrichers","\u002Fuse-cases\u002Fenrichers","5.use-cases\u002F5.enrichers","i-lucide-sparkles",{"title":433,"path":434,"stem":435},"eve","\u002Fuse-cases\u002Feve","5.use-cases\u002F5.eve",{"title":437,"path":438,"stem":439,"children":440,"page":28},"Extend","\u002Fextend","6.extend",[441,445,450,455,459,464,468,472,476,481,486,491],{"title":128,"path":442,"stem":443,"icon":444},"\u002Fextend\u002Foverview","6.extend\u002F0.overview","i-lucide-blocks",{"title":446,"path":447,"stem":448,"icon":449},"Stream","\u002Fextend\u002Fstream","6.extend\u002F1.stream","i-lucide-radio-tower",{"title":451,"path":452,"stem":453,"icon":454},"Custom framework","\u002Fextend\u002Fcustom-framework","6.extend\u002F10.custom-framework","i-lucide-puzzle",{"title":456,"path":457,"stem":458,"icon":449},"Diagnostics channel","\u002Fextend\u002Fdiagnostics-channel","6.extend\u002F11.diagnostics-channel",{"title":460,"path":461,"stem":462,"icon":463},"FS reader","\u002Fextend\u002Ffs-reader","6.extend\u002F2.fs-reader","i-lucide-folder-search",{"title":403,"path":465,"stem":466,"icon":467},"\u002Fextend\u002Fconsumer-recipes","6.extend\u002F3.consumer-recipes","i-lucide-chef-hat",{"title":469,"path":470,"stem":471},"Plugins","\u002Fextend\u002Fplugins","6.extend\u002F4.plugins",{"title":473,"path":474,"stem":475,"icon":431},"Custom enrichers","\u002Fextend\u002Fcustom-enrichers","6.extend\u002F5.custom-enrichers",{"title":477,"path":478,"stem":479,"icon":480},"Tail sampling","\u002Fextend\u002Ftail-sampling","6.extend\u002F6.tail-sampling","i-lucide-filter",{"title":482,"path":483,"stem":484,"icon":485},"Identity headers","\u002Fextend\u002Fidentity-headers","6.extend\u002F7.identity-headers","i-lucide-fingerprint",{"title":487,"path":488,"stem":489,"icon":490},"Custom drains","\u002Fextend\u002Fcustom-drains","6.extend\u002F8.custom-drains","i-lucide-share-2",{"title":492,"path":493,"stem":494},"Drain Pipeline","\u002Fextend\u002Fdrain-pipeline","6.extend\u002F9.drain-pipeline",{"title":424,"path":496,"stem":497,"children":498,"page":28},"\u002Freference","7.reference",[499,503,508,511,516,520,525,529],{"title":128,"path":500,"stem":501,"icon":502},"\u002Freference\u002Foverview","7.reference\u002F0.overview","i-lucide-book-marked",{"title":504,"path":505,"stem":506,"icon":507},"Configuration","\u002Freference\u002Fconfiguration","7.reference\u002F1.configuration","i-lucide-settings",{"title":370,"path":509,"stem":510,"icon":373},"\u002Freference\u002Fperformance","7.reference\u002F2.performance",{"title":512,"path":513,"stem":514,"icon":515},"Vite Plugin","\u002Freference\u002Fvite-plugin","7.reference\u002F3.vite-plugin","i-custom-vite",{"title":517,"path":518,"stem":519,"icon":376},"Best Practices","\u002Freference\u002Fbest-practices","7.reference\u002F4.best-practices",{"title":521,"path":522,"stem":523,"icon":524},"vs Other Loggers","\u002Freference\u002Fvs-other-loggers","7.reference\u002F5.vs-other-loggers","i-lucide-scale",{"title":526,"path":527,"stem":528,"icon":431},"Agent Skills","\u002Freference\u002Fagent-skills","7.reference\u002F6.agent-skills",{"title":530,"path":531,"stem":532},"Log cost","\u002Freference\u002Fcost","7.reference\u002F7.cost",{"id":534,"title":446,"body":535,"description":2073,"extension":2074,"links":2075,"meta":2076,"navigation":2077,"path":447,"seo":2078,"stem":448,"__hash__":2079},"docs\u002F6.extend\u002F1.stream.md",{"type":536,"value":537,"toc":2060},"minimark",[538,547,571,586,590,593,598,675,994,998,1085,1094,1098,1101,1110,1116,1186,1190,1196,1234,1237,1241,1510,1523,1527,1530,1546,1549,1621,1624,1679,1683,1689,1777,1943,1947,2039,2043,2056],[539,540,541,542,546],"p",{},"evlog ships a ",[543,544,545],"strong",{},"stream primitive"," so any local consumer can subscribe to wide events without re-implementing a drain. There are two layers, building on each other:",[548,549,550,562],"ul",{},[551,552,553,556,557,561],"li",{},[543,554,555],{},"In-process bus",": ",[558,559,560],"code",{},"createStreamDrain()",", the canonical pub\u002Fsub. Sync listeners, async iterators, ring-buffered replay.",[551,563,564,556,567,570],{},[543,565,566],{},"Network bridge",[558,568,569],{},"startStreamServer()",", an opt-in HTTP mini-server that exposes the in-process bus over Server-Sent Events for browsers, CLIs, or external devtools.",[572,573,574,577,578,581,582,585],"callout",{"icon":364},[543,575,576],{},"Local-only by design."," Both layers live inside a single Node \u002F Bun \u002F Deno process. They work in ",[558,579,580],{},"pnpm dev",", on long-lived self-hosted servers, on VMs and containers (Fly, Railway, Coolify…). They do ",[543,583,584],{},"not"," work on serverless platforms (Vercel Functions, Cloudflare Workers, AWS Lambda), each invocation is an isolated process. Use a real broker (Redis Streams, NATS, Pub\u002FSub) for cross-instance fan-out there.",[587,588,555],"h2",{"id":589},"in-process-bus",[591,592],"stream-bus",{},[539,594,595,597],{},[558,596,560],{}," is just a drain. Register it on the evlog drain hook and subscribe to events as they're emitted: no HTTP, no serialization, no extra hops.",[599,600,603,606,666],"prompt",{":actions":601,"description":602,"icon":449},"[\"copy\",\"cursor\",\"claude\"]","Subscribe to wide events in-process",[539,604,605],{},"Wire an in-process subscriber on top of evlog's stream drain.",[548,607,608,619,634,645,652,663],{},[551,609,610,611,614,615,618],{},"Import ",[558,612,613],{},"createStreamDrain"," from ",[558,616,617],{},"evlog\u002Fstream"," and call it once at app boot",[551,620,621,622,625,626,629,630,633],{},"Register the returned ",[558,623,624],{},"drain"," on the evlog drain hook for my framework (Nitro: ",[558,627,628],{},"nitroApp.hooks.hook('evlog:drain', stream.drain)","; Next\u002Fstandalone: pass to ",[558,631,632],{},"initLogger({ drain })",")",[551,635,636,637,640,641,644],{},"Subscribe with ",[558,638,639],{},"stream.subscribe((event) => ...)"," for sync listeners or ",[558,642,643],{},"for await (const event of stream.events())"," for async iteration",[551,646,647,648,651],{},"Seed history for late subscribers with ",[558,649,650],{},"stream.recent()"," (snapshot of the ring buffer) before opening the live iterator",[551,653,654,655,658,659,662],{},"Tune ",[558,656,657],{},"buffer"," for replay history and ",[558,660,661],{},"perSubscriberQueue"," for slow-consumer backpressure",[551,664,665],{},"Skip on serverless platforms. The stream is in-process, so isolated invocations won't share it",[539,667,668,669],{},"Docs: ",[670,671,672],"a",{"href":672,"rel":673},"https:\u002F\u002Fwww.evlog.dev\u002Fextend\u002Fstream",[674],"nofollow",[676,677,682],"pre",{"className":678,"code":679,"language":680,"meta":681,"style":681},"language-ts shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","import { createStreamDrain } from 'evlog\u002Fstream'\n\nconst stream = createStreamDrain({ buffer: 200 })\n\nnitroApp.hooks.hook('evlog:drain', stream.drain)\n\nconst off = stream.subscribe((event) => {\n  if (event.level === 'error') notify(event)\n})\noff()\n\nfor (const past of stream.recent()) {\n  bootstrap(past)\n}\nfor await (const event of stream.events()) {\n  bootstrap(event)\n}\n","ts","",[558,683,684,716,723,761,766,804,809,842,880,888,897,902,931,944,950,978,989],{"__ignoreMap":681},[685,686,689,693,697,701,704,707,710,713],"span",{"class":687,"line":688},"line",1,[685,690,692],{"class":691},"s7zQu","import",[685,694,696],{"class":695},"sMK4o"," {",[685,698,700],{"class":699},"sTEyZ"," createStreamDrain",[685,702,703],{"class":695}," }",[685,705,706],{"class":691}," from",[685,708,709],{"class":695}," '",[685,711,617],{"class":712},"sfazB",[685,714,715],{"class":695},"'\n",[685,717,719],{"class":687,"line":718},2,[685,720,722],{"emptyLinePlaceholder":721},true,"\n",[685,724,726,730,733,736,739,742,745,749,752,756,758],{"class":687,"line":725},3,[685,727,729],{"class":728},"spNyl","const",[685,731,732],{"class":699}," stream ",[685,734,735],{"class":695},"=",[685,737,700],{"class":738},"s2Zo4",[685,740,741],{"class":699},"(",[685,743,744],{"class":695},"{",[685,746,748],{"class":747},"swJcz"," buffer",[685,750,751],{"class":695},":",[685,753,755],{"class":754},"sbssI"," 200",[685,757,703],{"class":695},[685,759,760],{"class":699},")\n",[685,762,764],{"class":687,"line":763},4,[685,765,722],{"emptyLinePlaceholder":721},[685,767,769,772,775,778,780,783,785,788,791,793,796,799,801],{"class":687,"line":768},5,[685,770,771],{"class":699},"nitroApp",[685,773,774],{"class":695},".",[685,776,777],{"class":699},"hooks",[685,779,774],{"class":695},[685,781,782],{"class":738},"hook",[685,784,741],{"class":699},[685,786,787],{"class":695},"'",[685,789,790],{"class":712},"evlog:drain",[685,792,787],{"class":695},[685,794,795],{"class":695},",",[685,797,798],{"class":699}," stream",[685,800,774],{"class":695},[685,802,803],{"class":699},"drain)\n",[685,805,807],{"class":687,"line":806},6,[685,808,722],{"emptyLinePlaceholder":721},[685,810,812,814,817,819,821,823,826,828,830,834,836,839],{"class":687,"line":811},7,[685,813,729],{"class":728},[685,815,816],{"class":699}," off ",[685,818,735],{"class":695},[685,820,798],{"class":699},[685,822,774],{"class":695},[685,824,825],{"class":738},"subscribe",[685,827,741],{"class":699},[685,829,741],{"class":695},[685,831,833],{"class":832},"sHdIc","event",[685,835,633],{"class":695},[685,837,838],{"class":728}," =>",[685,840,841],{"class":695}," {\n",[685,843,845,848,851,853,855,858,861,863,866,868,871,874,876,878],{"class":687,"line":844},8,[685,846,847],{"class":691},"  if",[685,849,850],{"class":747}," (",[685,852,833],{"class":699},[685,854,774],{"class":695},[685,856,857],{"class":699},"level",[685,859,860],{"class":695}," ===",[685,862,709],{"class":695},[685,864,865],{"class":712},"error",[685,867,787],{"class":695},[685,869,870],{"class":747},") ",[685,872,873],{"class":738},"notify",[685,875,741],{"class":747},[685,877,833],{"class":699},[685,879,760],{"class":747},[685,881,883,886],{"class":687,"line":882},9,[685,884,885],{"class":695},"}",[685,887,760],{"class":699},[685,889,891,894],{"class":687,"line":890},10,[685,892,893],{"class":738},"off",[685,895,896],{"class":699},"()\n",[685,898,900],{"class":687,"line":899},11,[685,901,722],{"emptyLinePlaceholder":721},[685,903,905,908,910,912,915,918,920,922,925,928],{"class":687,"line":904},12,[685,906,907],{"class":691},"for",[685,909,850],{"class":699},[685,911,729],{"class":728},[685,913,914],{"class":699}," past ",[685,916,917],{"class":695},"of",[685,919,798],{"class":699},[685,921,774],{"class":695},[685,923,924],{"class":738},"recent",[685,926,927],{"class":699},"()) ",[685,929,930],{"class":695},"{\n",[685,932,934,937,939,942],{"class":687,"line":933},13,[685,935,936],{"class":738},"  bootstrap",[685,938,741],{"class":747},[685,940,941],{"class":699},"past",[685,943,760],{"class":747},[685,945,947],{"class":687,"line":946},14,[685,948,949],{"class":695},"}\n",[685,951,953,955,958,960,962,965,967,969,971,974,976],{"class":687,"line":952},15,[685,954,907],{"class":691},[685,956,957],{"class":691}," await",[685,959,850],{"class":699},[685,961,729],{"class":728},[685,963,964],{"class":699}," event ",[685,966,917],{"class":695},[685,968,798],{"class":699},[685,970,774],{"class":695},[685,972,973],{"class":738},"events",[685,975,927],{"class":699},[685,977,930],{"class":695},[685,979,981,983,985,987],{"class":687,"line":980},16,[685,982,936],{"class":738},[685,984,741],{"class":747},[685,986,833],{"class":699},[685,988,760],{"class":747},[685,990,992],{"class":687,"line":991},17,[685,993,949],{"class":695},[995,996,332],"h3",{"id":997},"options",[999,1000,1001,1017],"table",{},[1002,1003,1004],"thead",{},[1005,1006,1007,1011,1014],"tr",{},[1008,1009,1010],"th",{},"Option",[1008,1012,1013],{},"Type",[1008,1015,1016],{},"Description",[1018,1019,1020,1046,1066],"tbody",{},[1005,1021,1022,1027,1032],{},[1023,1024,1025],"td",{},[558,1026,657],{},[1023,1028,1029],{},[558,1030,1031],{},"number",[1023,1033,1034,1035,1038,1039,1042,1043,774],{},"Ring-buffer size for ",[558,1036,1037],{},"recent()"," snapshots. Set to ",[558,1040,1041],{},"0"," to disable. Default: ",[558,1044,1045],{},"500",[1005,1047,1048,1052,1056],{},[1023,1049,1050],{},[558,1051,661],{},[1023,1053,1054],{},[558,1055,1031],{},[1023,1057,1058,1059,1062,1063,774],{},"Max queued events per ",[558,1060,1061],{},"events()"," async iterator before the oldest are dropped. The drain itself is never blocked. Default: ",[558,1064,1065],{},"1000",[1005,1067,1068,1073,1078],{},[1023,1069,1070],{},[558,1071,1072],{},"filter",[1023,1074,1075],{},[558,1076,1077],{},"(event) => boolean",[1023,1079,1080,1081,1084],{},"Optional predicate run on each drained event — return ",[558,1082,1083],{},"false"," to skip the event entirely (neither buffered nor delivered).",[539,1086,1087,1090,1091,1093],{},[558,1088,1089],{},"stream.drain(events)"," accepts either a single event or a batch. ",[558,1092,650],{}," returns a snapshot of the buffered events (oldest first, most recent last) for ad-hoc inspection or to seed a UI panel.",[587,1095,1097],{"id":1096},"network-bridge-stream-server","Network bridge: stream server",[1099,1100],"sse-wire",{},[539,1102,1103,1105,1106,1109],{},[558,1104,569],{}," boots a tiny ",[558,1107,1108],{},"node:http"," server in the same process as your app, on its own ephemeral port, and exposes the in-process bus over Server-Sent Events. Any consumer (browser tab, CLI, Tauri\u002FElectron devtool) can subscribe, and your application API is untouched.",[572,1111,1112,1115],{"icon":364},[543,1113,1114],{},"Strict opt-in."," Nothing starts unless you set the option explicitly. There is no auto-enable in dev, and the server only boots when you ask for it.",[599,1117,1120,1123,1181],{":actions":601,"description":1118,"icon":1119},"Expose the evlog stream over SSE","i-lucide-radio",[539,1121,1122],{},"Turn on the local stream server so I can subscribe to wide events from a browser tab, CLI, or Tauri\u002FElectron devtool.",[548,1124,1125,1149,1156,1167,1178],{},[551,1126,1127,1128,1131,1132,1135,1136,1131,1139,1142,1143,1145,1146,1148],{},"Detect my framework and opt in explicitly (Nuxt: ",[558,1129,1130],{},"evlog.stream: true"," in ",[558,1133,1134],{},"nuxt.config.ts","; Next.js: ",[558,1137,1138],{},"defineStreamedInstrumentation({ stream: true })",[558,1140,1141],{},"instrumentation.ts","; Hono\u002FExpress\u002FFastify\u002FElysia\u002Fstandalone: call ",[558,1144,569],{}," once at boot and register the returned ",[558,1147,624],{}," on the evlog drain hook)",[551,1150,1151,1152,1155],{},"Never enable in production by default; gate it behind ",[558,1153,1154],{},"process.env.NODE_ENV !== 'production'"," or a feature flag",[551,1157,1158,1159,1162,1163,1166],{},"For shared dev environments, set ",[558,1160,1161],{},"token: process.env.EVLOG_STREAM_TOKEN"," and have the consumer send it as ",[558,1164,1165],{},"Authorization: Bearer \u003Ctoken>"," on every request",[551,1168,1169,1170,1173,1174,1177],{},"Discover the URL from ",[558,1171,1172],{},".evlog\u002Fstream.url"," (or ",[558,1175,1176],{},"\u002Fapi\u002F_evlog\u002Fstream-info"," on Nuxt), and never hard-code the port, which is ephemeral",[551,1179,1180],{},"Skip on serverless platforms. The server is in-process",[539,1182,668,1183],{},[670,1184,672],{"href":672,"rel":1185},[674],[995,1187,1189],{"id":1188},"what-boots-up","What boots up",[539,1191,1192,1193,1195],{},"When you opt in, evlog calls ",[558,1194,569],{}," and:",[1197,1198,1199,1202,1212,1217,1220,1223],"ol",{},[551,1200,1201],{},"Picks an ephemeral free port (or the one you specify)",[551,1203,1204,1205,1207,1208,1211],{},"Spins a tiny ",[558,1206,1108],{}," server on ",[558,1209,1210],{},"127.0.0.1"," (or your host)",[551,1213,1214,1215],{},"Writes the discovered URL to ",[558,1216,1172],{},[551,1218,1219],{},"Prints a one-line banner in the server console",[551,1221,1222],{},"Hooks the in-process stream drain into the evlog pipeline",[551,1224,1225,1226,1229,1230,1233],{},"Exposes ",[558,1227,1228],{},"GET \u002F"," for the SSE stream and ",[558,1231,1232],{},"GET \u002Finfo"," for handshake metadata",[539,1235,1236],{},"On shutdown (SIGINT \u002F SIGTERM \u002F process exit) the server cleans up listeners and removes the URL file.",[995,1238,1240],{"id":1239},"per-framework-opt-in","Per-framework opt-in",[1242,1243,1244,1326,1395],"code-group",{},[676,1245,1247],{"className":678,"code":1246,"filename":1134,"language":680,"meta":681,"style":681},"export default defineNuxtConfig({\n  modules: ['evlog\u002Fnuxt'],\n  evlog: {\n    stream: true,\n    \u002F\u002F or: stream: { port: 4444, token: process.env.EVLOG_STREAM_TOKEN }\n  },\n})\n",[558,1248,1249,1264,1287,1296,1309,1315,1320],{"__ignoreMap":681},[685,1250,1251,1254,1257,1260,1262],{"class":687,"line":688},[685,1252,1253],{"class":691},"export",[685,1255,1256],{"class":691}," default",[685,1258,1259],{"class":738}," defineNuxtConfig",[685,1261,741],{"class":699},[685,1263,930],{"class":695},[685,1265,1266,1269,1271,1274,1276,1279,1281,1284],{"class":687,"line":718},[685,1267,1268],{"class":747},"  modules",[685,1270,751],{"class":695},[685,1272,1273],{"class":699}," [",[685,1275,787],{"class":695},[685,1277,1278],{"class":712},"evlog\u002Fnuxt",[685,1280,787],{"class":695},[685,1282,1283],{"class":699},"]",[685,1285,1286],{"class":695},",\n",[685,1288,1289,1292,1294],{"class":687,"line":725},[685,1290,1291],{"class":747},"  evlog",[685,1293,751],{"class":695},[685,1295,841],{"class":695},[685,1297,1298,1301,1303,1307],{"class":687,"line":763},[685,1299,1300],{"class":747},"    stream",[685,1302,751],{"class":695},[685,1304,1306],{"class":1305},"sfNiH"," true",[685,1308,1286],{"class":695},[685,1310,1311],{"class":687,"line":768},[685,1312,1314],{"class":1313},"sHwdD","    \u002F\u002F or: stream: { port: 4444, token: process.env.EVLOG_STREAM_TOKEN }\n",[685,1316,1317],{"class":687,"line":806},[685,1318,1319],{"class":695},"  },\n",[685,1321,1322,1324],{"class":687,"line":811},[685,1323,885],{"class":695},[685,1325,760],{"class":699},[676,1327,1329],{"className":678,"code":1328,"filename":1141,"language":680,"meta":681,"style":681},"import { defineStreamedInstrumentation } from 'evlog\u002Fnext\u002Fstream'\n\nexport const { register } = defineStreamedInstrumentation({\n  stream: true,\n})\n",[558,1330,1331,1351,1355,1378,1389],{"__ignoreMap":681},[685,1332,1333,1335,1337,1340,1342,1344,1346,1349],{"class":687,"line":688},[685,1334,692],{"class":691},[685,1336,696],{"class":695},[685,1338,1339],{"class":699}," defineStreamedInstrumentation",[685,1341,703],{"class":695},[685,1343,706],{"class":691},[685,1345,709],{"class":695},[685,1347,1348],{"class":712},"evlog\u002Fnext\u002Fstream",[685,1350,715],{"class":695},[685,1352,1353],{"class":687,"line":718},[685,1354,722],{"emptyLinePlaceholder":721},[685,1356,1357,1359,1362,1364,1367,1369,1372,1374,1376],{"class":687,"line":725},[685,1358,1253],{"class":691},[685,1360,1361],{"class":728}," const",[685,1363,696],{"class":695},[685,1365,1366],{"class":699}," register ",[685,1368,885],{"class":695},[685,1370,1371],{"class":695}," =",[685,1373,1339],{"class":738},[685,1375,741],{"class":699},[685,1377,930],{"class":695},[685,1379,1380,1383,1385,1387],{"class":687,"line":763},[685,1381,1382],{"class":747},"  stream",[685,1384,751],{"class":695},[685,1386,1306],{"class":1305},[685,1388,1286],{"class":695},[685,1390,1391,1393],{"class":687,"line":768},[685,1392,885],{"class":695},[685,1394,760],{"class":699},[676,1396,1399],{"className":678,"code":1397,"filename":1398,"language":680,"meta":681,"style":681},"import { startStreamServer } from 'evlog\u002Fstream'\n\nif (process.env.NODE_ENV !== 'production' && process.env.EVLOG_STREAM === '1') {\n  const { drain } = await startStreamServer()\n  \u002F\u002F Plug `drain` into the evlog drain hook for your framework\n}\n","Hono \u002F Express \u002F Fastify \u002F standalone",[558,1400,1401,1420,1424,1481,1501,1506],{"__ignoreMap":681},[685,1402,1403,1405,1407,1410,1412,1414,1416,1418],{"class":687,"line":688},[685,1404,692],{"class":691},[685,1406,696],{"class":695},[685,1408,1409],{"class":699}," startStreamServer",[685,1411,703],{"class":695},[685,1413,706],{"class":691},[685,1415,709],{"class":695},[685,1417,617],{"class":712},[685,1419,715],{"class":695},[685,1421,1422],{"class":687,"line":718},[685,1423,722],{"emptyLinePlaceholder":721},[685,1425,1426,1429,1432,1434,1437,1439,1442,1445,1447,1450,1452,1455,1458,1460,1462,1464,1467,1470,1472,1475,1477,1479],{"class":687,"line":725},[685,1427,1428],{"class":691},"if",[685,1430,1431],{"class":699}," (process",[685,1433,774],{"class":695},[685,1435,1436],{"class":699},"env",[685,1438,774],{"class":695},[685,1440,1441],{"class":699},"NODE_ENV ",[685,1443,1444],{"class":695},"!==",[685,1446,709],{"class":695},[685,1448,1449],{"class":712},"production",[685,1451,787],{"class":695},[685,1453,1454],{"class":695}," &&",[685,1456,1457],{"class":699}," process",[685,1459,774],{"class":695},[685,1461,1436],{"class":699},[685,1463,774],{"class":695},[685,1465,1466],{"class":699},"EVLOG_STREAM ",[685,1468,1469],{"class":695},"===",[685,1471,709],{"class":695},[685,1473,1474],{"class":712},"1",[685,1476,787],{"class":695},[685,1478,870],{"class":699},[685,1480,930],{"class":695},[685,1482,1483,1486,1488,1491,1493,1495,1497,1499],{"class":687,"line":763},[685,1484,1485],{"class":728},"  const",[685,1487,696],{"class":695},[685,1489,1490],{"class":699}," drain",[685,1492,703],{"class":695},[685,1494,1371],{"class":695},[685,1496,957],{"class":691},[685,1498,1409],{"class":738},[685,1500,896],{"class":747},[685,1502,1503],{"class":687,"line":768},[685,1504,1505],{"class":1313},"  \u002F\u002F Plug `drain` into the evlog drain hook for your framework\n",[685,1507,1508],{"class":687,"line":806},[685,1509,949],{"class":695},[539,1511,1512,1513,1515,1516,1519,1520,1522],{},"The Hono \u002F Express \u002F Fastify integrations don't need a \"feature PR\", because ",[558,1514,569],{}," is ",[543,1517,1518],{},"orthogonal"," to your framework. You boot it once and connect its ",[558,1521,624],{}," to the evlog pipeline like any other drain.",[995,1524,1526],{"id":1525},"discovery","Discovery",[539,1528,1529],{},"The mini-server runs on a random port, so any consumer must discover it.",[676,1531,1533],{"className":678,"code":1532,"filename":1172,"language":680,"meta":681,"style":681},"http:\u002F\u002F127.0.0.1:53942\n",[558,1534,1535],{"__ignoreMap":681},[685,1536,1537,1541,1543],{"class":687,"line":688},[685,1538,1540],{"class":1539},"sBMFI","http",[685,1542,751],{"class":695},[685,1544,1545],{"class":1313},"\u002F\u002F127.0.0.1:53942\n",[539,1547,1548],{},"Read directly from disk:",[676,1550,1552],{"className":678,"code":1551,"language":680,"meta":681,"style":681},"import { readFile } from 'node:fs\u002Fpromises'\n\nconst url = (await readFile('.evlog\u002Fstream.url', 'utf-8')).trim()\n",[558,1553,1554,1574,1578],{"__ignoreMap":681},[685,1555,1556,1558,1560,1563,1565,1567,1569,1572],{"class":687,"line":688},[685,1557,692],{"class":691},[685,1559,696],{"class":695},[685,1561,1562],{"class":699}," readFile",[685,1564,703],{"class":695},[685,1566,706],{"class":691},[685,1568,709],{"class":695},[685,1570,1571],{"class":712},"node:fs\u002Fpromises",[685,1573,715],{"class":695},[685,1575,1576],{"class":687,"line":718},[685,1577,722],{"emptyLinePlaceholder":721},[685,1579,1580,1582,1585,1587,1589,1592,1594,1596,1598,1600,1602,1604,1606,1609,1611,1614,1616,1619],{"class":687,"line":725},[685,1581,729],{"class":728},[685,1583,1584],{"class":699}," url ",[685,1586,735],{"class":695},[685,1588,850],{"class":699},[685,1590,1591],{"class":691},"await",[685,1593,1562],{"class":738},[685,1595,741],{"class":699},[685,1597,787],{"class":695},[685,1599,1172],{"class":712},[685,1601,787],{"class":695},[685,1603,795],{"class":695},[685,1605,709],{"class":695},[685,1607,1608],{"class":712},"utf-8",[685,1610,787],{"class":695},[685,1612,1613],{"class":699},"))",[685,1615,774],{"class":695},[685,1617,1618],{"class":738},"trim",[685,1620,896],{"class":699},[539,1622,1623],{},"Or, for same-origin browser tabs in a Nuxt app, hit the discovery route:",[676,1625,1627],{"className":678,"code":1626,"language":680,"meta":681,"style":681},"const { url } = await fetch('\u002Fapi\u002F_evlog\u002Fstream-info').then(r => r.json())\n",[558,1628,1629],{"__ignoreMap":681},[685,1630,1631,1633,1635,1637,1639,1641,1643,1646,1648,1650,1652,1654,1656,1658,1661,1663,1666,1668,1671,1673,1676],{"class":687,"line":688},[685,1632,729],{"class":728},[685,1634,696],{"class":695},[685,1636,1584],{"class":699},[685,1638,885],{"class":695},[685,1640,1371],{"class":695},[685,1642,957],{"class":691},[685,1644,1645],{"class":738}," fetch",[685,1647,741],{"class":699},[685,1649,787],{"class":695},[685,1651,1176],{"class":712},[685,1653,787],{"class":695},[685,1655,633],{"class":699},[685,1657,774],{"class":695},[685,1659,1660],{"class":738},"then",[685,1662,741],{"class":699},[685,1664,1665],{"class":832},"r",[685,1667,838],{"class":728},[685,1669,1670],{"class":699}," r",[685,1672,774],{"class":695},[685,1674,1675],{"class":738},"json",[685,1677,1678],{"class":699},"())\n",[995,1680,1682],{"id":1681},"wire-format","Wire format",[539,1684,1685,1686,751],{},"Every SSE message has the shape ",[558,1687,1688],{},"{ evlog: '1', type, data }",[999,1690,1691,1708],{},[1002,1692,1693],{},[1005,1694,1695,1700,1703],{},[1008,1696,1697],{},[558,1698,1699],{},"type",[1008,1701,1702],{},"When",[1008,1704,1705],{},[558,1706,1707],{},"data",[1018,1709,1710,1725,1746,1759],{},[1005,1711,1712,1717,1720],{},[1023,1713,1714],{},[558,1715,1716],{},"hello",[1023,1718,1719],{},"First frame after connect",[1023,1721,1722],{},[558,1723,1724],{},"{ evlogVersion, bufferSize, heartbeatMs }",[1005,1726,1727,1732,1741],{},[1023,1728,1729],{},[558,1730,1731],{},"replay",[1023,1733,1734,1735,1737,1738],{},"Right after ",[558,1736,1716],{},", replays buffered events when the consumer passed ",[558,1739,1740],{},"?since=\u003Ciso>",[1023,1742,1743],{},[558,1744,1745],{},"WideEvent",[1005,1747,1748,1752,1755],{},[1023,1749,1750],{},[558,1751,833],{},[1023,1753,1754],{},"Every emitted event after that",[1023,1756,1757],{},[558,1758,1745],{},[1005,1760,1761,1766,1772],{},[1023,1762,1763],{},[558,1764,1765],{},"ping",[1023,1767,1768,1769,633],{},"Heartbeat (default every 15s, configurable via ",[558,1770,1771],{},"heartbeatMs",[1023,1773,1774],{},[558,1775,1776],{},"{ ts: number }",[676,1778,1781],{"className":678,"code":1779,"filename":1780,"language":680,"meta":681,"style":681},"const { url } = await fetch('\u002Fapi\u002F_evlog\u002Fstream-info').then(r => r.json())\nconst es = new EventSource(url)\n\nes.onmessage = (msg) => {\n  const { type, data } = JSON.parse(msg.data)\n  if (type === 'event') events.push(data)\n}\n","Browser consumer",[558,1782,1783,1827,1845,1849,1872,1908,1939],{"__ignoreMap":681},[685,1784,1785,1787,1789,1791,1793,1795,1797,1799,1801,1803,1805,1807,1809,1811,1813,1815,1817,1819,1821,1823,1825],{"class":687,"line":688},[685,1786,729],{"class":728},[685,1788,696],{"class":695},[685,1790,1584],{"class":699},[685,1792,885],{"class":695},[685,1794,1371],{"class":695},[685,1796,957],{"class":691},[685,1798,1645],{"class":738},[685,1800,741],{"class":699},[685,1802,787],{"class":695},[685,1804,1176],{"class":712},[685,1806,787],{"class":695},[685,1808,633],{"class":699},[685,1810,774],{"class":695},[685,1812,1660],{"class":738},[685,1814,741],{"class":699},[685,1816,1665],{"class":832},[685,1818,838],{"class":728},[685,1820,1670],{"class":699},[685,1822,774],{"class":695},[685,1824,1675],{"class":738},[685,1826,1678],{"class":699},[685,1828,1829,1831,1834,1836,1839,1842],{"class":687,"line":718},[685,1830,729],{"class":728},[685,1832,1833],{"class":699}," es ",[685,1835,735],{"class":695},[685,1837,1838],{"class":695}," new",[685,1840,1841],{"class":738}," EventSource",[685,1843,1844],{"class":699},"(url)\n",[685,1846,1847],{"class":687,"line":725},[685,1848,722],{"emptyLinePlaceholder":721},[685,1850,1851,1854,1856,1859,1861,1863,1866,1868,1870],{"class":687,"line":763},[685,1852,1853],{"class":699},"es",[685,1855,774],{"class":695},[685,1857,1858],{"class":738},"onmessage",[685,1860,1371],{"class":695},[685,1862,850],{"class":695},[685,1864,1865],{"class":832},"msg",[685,1867,633],{"class":695},[685,1869,838],{"class":728},[685,1871,841],{"class":695},[685,1873,1874,1876,1878,1881,1883,1886,1888,1890,1893,1895,1898,1900,1902,1904,1906],{"class":687,"line":768},[685,1875,1485],{"class":728},[685,1877,696],{"class":695},[685,1879,1880],{"class":699}," type",[685,1882,795],{"class":695},[685,1884,1885],{"class":699}," data",[685,1887,703],{"class":695},[685,1889,1371],{"class":695},[685,1891,1892],{"class":699}," JSON",[685,1894,774],{"class":695},[685,1896,1897],{"class":738},"parse",[685,1899,741],{"class":747},[685,1901,1865],{"class":699},[685,1903,774],{"class":695},[685,1905,1707],{"class":699},[685,1907,760],{"class":747},[685,1909,1910,1912,1914,1916,1918,1920,1922,1924,1926,1928,1930,1933,1935,1937],{"class":687,"line":806},[685,1911,847],{"class":691},[685,1913,850],{"class":747},[685,1915,1699],{"class":699},[685,1917,860],{"class":695},[685,1919,709],{"class":695},[685,1921,833],{"class":712},[685,1923,787],{"class":695},[685,1925,870],{"class":747},[685,1927,973],{"class":699},[685,1929,774],{"class":695},[685,1931,1932],{"class":738},"push",[685,1934,741],{"class":747},[685,1936,1707],{"class":699},[685,1938,760],{"class":747},[685,1940,1941],{"class":687,"line":811},[685,1942,949],{"class":695},[995,1944,1946],{"id":1945},"auth-cors","Auth + CORS",[999,1948,1949,1958],{},[1002,1950,1951],{},[1005,1952,1953,1955],{},[1008,1954,1010],{},[1008,1956,1957],{},"Behavior",[1018,1959,1960,1973,1995,2012,2025],{},[1005,1961,1962,1967],{},[1023,1963,1964],{},[558,1965,1966],{},"token",[1023,1968,1969,1970,1972],{},"When set, the server requires ",[558,1971,1165],{}," on every request and 401s otherwise.",[1005,1974,1975,1978],{},[1023,1976,1977],{},"(no token)",[1023,1979,1980,1981,1984,1985,1987,1988,1987,1991,1994],{},"Connections are accepted only when there is no ",[558,1982,1983],{},"Origin"," header or the origin host is local (",[558,1986,1210],{}," \u002F ",[558,1989,1990],{},"localhost",[558,1992,1993],{},"[::1]","). Other origins receive 403.",[1005,1996,1997,2002],{},[1023,1998,1999],{},[558,2000,2001],{},"host",[1023,2003,2004,2005,2007,2008,2011],{},"Default ",[558,2006,1210],{}," — never reachable from the LAN. Override to ",[558,2009,2010],{},"0.0.0.0"," only with a token set.",[1005,2013,2014,2018],{},[1023,2015,2016],{},[558,2017,1771],{},[1023,2019,2020,2021,2024],{},"Heartbeat interval (default ",[558,2022,2023],{},"15000",").",[1005,2026,2027,2031],{},[1023,2028,2029],{},[558,2030,657],{},[1023,2032,2033,2034,2036,2037,774],{},"Ring buffer kept on the underlying default stream — replayed for late-joining clients via ",[558,2035,1740],{},". Default ",[558,2038,1045],{},[587,2040,2042],{"id":2041},"going-further","Going further",[548,2044,2045,2050],{},[551,2046,2047,2049],{},[670,2048,460],{"href":461},": replay or tail historic NDJSON files (cross-process, survives restarts)",[551,2051,2052,2055],{},[670,2053,2054],{"href":465},"Consumer recipes",": build a minimal devtool, pipe to curl + jq, replay history then go live",[2057,2058,2059],"style",{},"html pre.shiki code .s7zQu, html code.shiki .s7zQu{--shiki-light:#39ADB5;--shiki-light-font-style:italic;--shiki-default:#89DDFF;--shiki-default-font-style:italic;--shiki-dark:#89DDFF;--shiki-dark-font-style:italic}html pre.shiki code .sMK4o, html code.shiki .sMK4o{--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF}html pre.shiki code .sTEyZ, html code.shiki .sTEyZ{--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8}html pre.shiki code .sfazB, html code.shiki .sfazB{--shiki-light:#91B859;--shiki-default:#C3E88D;--shiki-dark:#C3E88D}html pre.shiki code .spNyl, html code.shiki .spNyl{--shiki-light:#9C3EDA;--shiki-default:#C792EA;--shiki-dark:#C792EA}html pre.shiki code .s2Zo4, html code.shiki .s2Zo4{--shiki-light:#6182B8;--shiki-default:#82AAFF;--shiki-dark:#82AAFF}html pre.shiki code .swJcz, html code.shiki .swJcz{--shiki-light:#E53935;--shiki-default:#F07178;--shiki-dark:#F07178}html pre.shiki code .sbssI, html code.shiki .sbssI{--shiki-light:#F76D47;--shiki-default:#F78C6C;--shiki-dark:#F78C6C}html pre.shiki code .sHdIc, html code.shiki .sHdIc{--shiki-light:#90A4AE;--shiki-light-font-style:italic;--shiki-default:#EEFFFF;--shiki-default-font-style:italic;--shiki-dark:#BABED8;--shiki-dark-font-style:italic}html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html pre.shiki code .sfNiH, html code.shiki .sfNiH{--shiki-light:#FF5370;--shiki-default:#FF9CAC;--shiki-dark:#FF9CAC}html pre.shiki code .sHwdD, html code.shiki .sHwdD{--shiki-light:#90A4AE;--shiki-light-font-style:italic;--shiki-default:#546E7A;--shiki-default-font-style:italic;--shiki-dark:#676E95;--shiki-dark-font-style:italic}html pre.shiki code .sBMFI, html code.shiki .sBMFI{--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B}",{"title":681,"searchDepth":718,"depth":718,"links":2061},[2062,2065,2072],{"id":589,"depth":718,"text":555,"children":2063},[2064],{"id":997,"depth":725,"text":332},{"id":1096,"depth":718,"text":1097,"children":2066},[2067,2068,2069,2070,2071],{"id":1188,"depth":725,"text":1189},{"id":1239,"depth":725,"text":1240},{"id":1525,"depth":725,"text":1526},{"id":1681,"depth":725,"text":1682},{"id":1945,"depth":725,"text":1946},{"id":2041,"depth":718,"text":2042},"Subscribe to wide events flowing through evlog — in-process with createStreamDrain, or over the network with the local SSE stream server.","md",null,{},{"title":446,"icon":449},{"title":446,"description":2073},"awgcJwxj8IvIwn0X-16ptW8hwlFTuLdsNWk3RbpW2wU",[2081,2083],{"title":128,"path":442,"stem":443,"description":2082,"icon":444,"children":-1},"Observe what flows through the pipeline, plug into it, or build your own bricks. The map of every extension point evlog exposes.",{"title":451,"path":452,"stem":453,"description":2084,"icon":454,"children":-1},"Build evlog support for a framework or runtime that has no integration, with defineFrameworkIntegration or the lower-level helpers.",1786806601289]