Interface BrowserDataSystemOptions

Data system options for the browser SDK.

The browser SDK does not support automatic mode switching (lifecycle or network-based). Use false (the default) to disable automatic switching, or ManualModeSwitching to specify an explicit initial connection mode.

This interface is not stable, and not subject to any backwards compatibility guarantees or semantic versioning. It is in early access. If you want access to this feature please join the EAP. https://launchdarkly.com/docs/sdk/features/data-saving-mode

Hierarchy

  • Omit<LDClientDataSystemOptions, "automaticModeSwitching">
    • BrowserDataSystemOptions

Properties

automaticModeSwitching?: false | ManualModeSwitching
connectionModes?: Partial<Record<FDv2ConnectionMode, ModeDefinition>>

Override the data source pipeline for specific connection modes.

Each key is a connection mode name ('streaming', 'polling', 'offline', 'one-shot', 'background'). The value defines the initializers and synchronizers for that mode, replacing the built-in defaults.

Only the modes you specify are overridden — unspecified modes retain their built-in definitions.

Example

connectionModes: {
streaming: {
initializers: [{ type: 'polling' }],
synchronizers: [{ type: 'streaming' }],
},
}

Generated using TypeDoc