跳到主要内容

ui/build/storage-scope

ui/build/storage-scope

Functions

currentStorageScope()

function currentStorageScope(): string | null;

Defined in: apps/website/.api-docs-entry/ui/build/storage-scope/index.d.ts:3

Returns

string | null


scopedStorageKey()

function scopedStorageKey(key): string;

Defined in: apps/website/.api-docs-entry/ui/build/storage-scope/index.d.ts:11

Namespace a key to the active tenant.

Before the shell has published a scope there is no tenant to attribute a key to, so the key is returned unscoped: an unscoped key can never collide with a scoped one, and the alternative — inventing a placeholder scope — would produce entries that no later session can find or clear.

Parameters

Parameter Type
key string

Returns

string


setStorageScope()

function setStorageScope(read): void;

Defined in: apps/website/.api-docs-entry/ui/build/storage-scope/index.d.ts:2

Provides the active organization from the workspace component that owns its lifetime.

Parameters

Parameter Type
read () => string | null

Returns

void