bun library
Bun listener adapters and runtime metadata for Routed applications.
Classes
- RoutedNodeCapabilities
- Capabilities declared by one host invocation.
- RoutedNodeContext
- Runtime-scoped host context carried through a Routed request.
- RoutedNodeExtension
- A typed lookup for host-owned request context values.
- RoutedNodeLifecycleEvent
-
Host lifecycle event published through Routed's existing
EventManager. - RoutedNodeRuntimeInfo
- Common runtime metadata exposed by a host adapter.
Enums
- RoutedNodeEntryModel
- Whether a host owns a long-lived listener or invokes a fetch export.
- RoutedNodeLifecyclePhase
-
Lifecycle phases emitted by a
routed_nodehost. - RoutedNodeRuntime
-
Runtime families supported by
routed_node.
Constants
- bunCapabilities → const RoutedNodeCapabilities
- Capabilities advertised by the Bun listener adapter.
Functions
-
publishRoutedNodeLifecycle(
Engine engine, RoutedNodeLifecycleEvent event) → void - Publishes a host lifecycle event when the engine has an EventManager.
-
serveBun(
Engine engine, {String host = '0.0.0.0', int port = 0}) → Future< ServerHandle> - Starts a Routed application on Bun.
-
serveJsListener(
String runtime, Engine engine, {required String host, required int port, required RoutedNodeRuntimeInfo info}) → Future< ServerHandle> - Starts a JavaScript listener using the supplied host server factory.