/**
* vapor-chamber - IIFE variant: FULL
*
* Exposes the full vapor-chamber API as `window.VaporChamber`. For sites that
* want every feature in a single `
*
*
*/
import { createCommandBus, createAsyncCommandBus, type BaseBus } from './command-bus';
import { logger, validator, history, authGuard, createChannel } from './plugins';
import { pace } from './pace';
import { bindCommands } from './command-binding';
import { bindDisplay } from './page-bindings';
import { saveTo, shareTabs } from './store/core';
import { httpTransport, wsTransport, createSseBridge } from './transports';
import { createApp, connect, type CreateAppOptions } from './iife-app';
import { createBuffer } from './buffer';
import { defineVaporCustomElement, defineVaporComponent, defineVaporAsyncComponent, defineVaporCommand, useVaporAsyncCommand, createVaporChamberApp, getVaporInteropPlugin } from './chamber-vapor';
import { useSharedCommandState, useCommand, configureVue } from './chamber';
import { commandState } from './command-state';
import { Accepted } from './accepted';
import { defineWidget, emitDOMEvent } from './widget';
/** A store definition, what `defineChamberStore(id, options)` returns: mount reads only `$dispose` of its store. */
type StoreDefinition = (bus: BaseBus) => {
$dispose: () => void;
};
export type MountOptions = Record> = CreateAppOptions & {
/** The island's stores, `{ name: defineChamberStore(id, options) }`, each created on the island's bus. */
stores?: D;
};
/**
* mount - an island on one element: its own bus, its stores on that bus, and
* the element's `data-vc-command` and display attributes bound to both
* (`bindCommands`, `bindDisplay`). The stores come back under their names.
* `unmount()` unbinds the element and disposes the stores. A selector that
* matches nothing binds nothing and warns in development.
* tests/iife-mount.test.ts.
*
* @example
* VaporChamber.mount('#analytics-island', {
* transport: VaporChamber.httpTransport({ endpoint: '/api/vc' }),
* stores: { analytics: VaporChamber.defineChamberStore('analytics', { state, reducers }) }
* })
*/
declare function mount = {}>(selector: string, options?: MountOptions): {
bus: ReturnType;
dispatch: ReturnType['dispatch'];
stores: {
[K in keyof D]: ReturnType;
};
el: Element | null;
unmount: () => void;
};
declare const VaporChamber: {
readonly createCommandBus: typeof createCommandBus;
readonly createAsyncCommandBus: typeof createAsyncCommandBus;
readonly createBuffer: typeof createBuffer;
readonly createApp: typeof createApp;
readonly connect: typeof connect;
readonly mount: typeof mount;
readonly defineWidget: typeof defineWidget;
readonly emitDOMEvent: typeof emitDOMEvent;
readonly httpTransport: typeof httpTransport;
readonly wsTransport: typeof wsTransport;
/** Server-sent events bridge. Alias for createSseBridge(). */
readonly sse: typeof createSseBridge;
readonly logger: typeof logger;
readonly validator: typeof validator;
readonly history: typeof history;
readonly authGuard: typeof authGuard;
readonly createChannel: typeof createChannel;
readonly pace: typeof pace;
readonly bindCommands: typeof bindCommands;
readonly bindDisplay: typeof bindDisplay;
/** The core store: `persist: saveTo({ key })` saves it, `share: shareTabs()` shares it across tabs, `$onField` follows a field. */
readonly defineChamberStore: | null>>(id: string, options: import("./store/core").ChamberStoreOptions) => (bus: B, router?: import("./store-base").StoreRouter) => import("./store-base").ChamberStore;
readonly saveTo: typeof saveTo;
readonly shareTabs: typeof shareTabs;
/** What is in flight on a bus and what failed: `pending(action, target?)`, `anyPending`, `errors`, `subscribe(fn)`. */
readonly commandState: typeof commandState;
/** A reply whose work goes on: `r.value instanceof Accepted`, `done` settles at the end. */
readonly Accepted: typeof Accepted;
readonly defineVaporCustomElement: typeof defineVaporCustomElement;
readonly defineVaporComponent: typeof defineVaporComponent;
readonly defineVaporAsyncComponent: typeof defineVaporAsyncComponent;
readonly defineVaporCommand: typeof defineVaporCommand;
readonly useCommand: typeof useCommand;
readonly useVaporAsyncCommand: typeof useVaporAsyncCommand;
readonly useSharedCommandState: typeof useSharedCommandState;
readonly createVaporChamberApp: typeof createVaporChamberApp;
readonly getVaporInteropPlugin: typeof getVaporInteropPlugin;
/**
* Hand Vue's namespace to the library - the only channel that works on a
* `