Skip to content

Latest commit

 

History

History
178 lines (105 loc) · 3.14 KB

File metadata and controls

178 lines (105 loc) · 3.14 KB

mps3 / MPS3

Class: MPS3

Table of contents

Constructors

Properties

Methods

Constructors

constructor

new MPS3(config): MPS3

Parameters

Name Type
config MPS3Config

Returns

MPS3

Defined in

mps3.ts:157

Properties

LOCAL_ENDPOINT

Static LOCAL_ENDPOINT: string = "indexdb:"

Virtual endpoint for local-first operation

Defined in

mps3.ts:135

Methods

delete

delete(ref, options?): Promise<unknown[]>

Parameters

Name Type
ref string | Ref
options Object
options.manifests? Ref[]

Returns

Promise<unknown[]>

Defined in

mps3.ts:366


get

get(ref, options?): Promise<undefined | JSONValue>

Parameters

Name Type
ref string | Ref
options Object
options.manifest? Ref

Returns

Promise<undefined | JSONValue>

Defined in

mps3.ts:237


put

put(ref, value, options?): Promise<unknown[]>

Parameters

Name Type
ref string | Ref
value undefined | JSONValue
options Object
options.await? "local" | "remote"
options.manifests? Ref[]

Returns

Promise<unknown[]>

Defined in

mps3.ts:375


putAll

putAll(values, options?): Promise<unknown[]>

Parameters

Name Type
values Map<string | Ref, undefined | JSONValue>
options Object
options.await? "local" | "remote"
options.isLoad? boolean
options.manifests? Ref[]

Returns

Promise<unknown[]>

Defined in

mps3.ts:386


subscribe

subscribe(key, handler, options?): () => void

Listen to a key for changes

Parameters

Name Type Description
key string | Ref
handler (value: undefined | JSONValue, error?: Error) => void callback to be notified of changes
options? Object -
options.manifest? Ref -

Returns

fn

unsubscribe function

▸ (): void

Returns

void

Defined in

mps3.ts:568