@wvb/electron
Webview Bundle API for Electron
Use @wvb/electron in your project and browse its exported API.
Installation
Add the package to your project's dependencies:
npm install @wvb/electronInstall the compatible host tools:
npm install -D "electron@>= 15"Functions
bundleProtocol
Creates a protocol that serves files from the configured bundle source.
isWebviewBundleError
Whether value is an error thrown by this binding.
proxyProtocol
Proxy the scheme to another server (a dev server with hot reload).
webviewBundle
Creates an Electron bundle manager and registers its renderer IPC transport.
Interfaces
BundleProtocolConfig
Options shared by bundle and proxy protocol registrations.
Protocol
A scheme, handler, and registration options managed by Webview Bundle.
ProtocolHandler
Handles one Fetch-compatible request for a registered protocol.
ProtocolOptions
Options shared by bundle and proxy protocol registrations.
RemoteOptions
Optional settings forwarded to the native remote client.
SourceOptions
Bundle source configuration with Electron-specific directory defaults.
WebviewBundle
Host-process facade for bundle sources, custom protocols, and optional remote updates.
WebviewBundleConfig
Configuration used to initialize the Electron integration.
WebviewBundleError
WebviewBundleRemoteConfig
Remote endpoint and options used by the optional updater.
Type Aliases
HostnameSegment
Which hostname segment is used as the bundle name.
ProxyProtocolConfig
Either a host → target mapping, or a resolver called with each request uri — never both.
ProxyResolver
Resolves the proxy target for a request uri (null to not proxy).
UriBundleResolver
Options for resolving the bundle name from the request uri.
UriPathResolver
How the file path in the bundle is resolved from the request uri.
WebviewBundleErrorCode
The stable code every error thrown by this binding carries (WebviewBundleError.code).