tinybase 6.1.0-beta.0 → 6.1.0-beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/@types/_internal/ui-react/with-schemas/index.d.ts +1 -1
- package/@types/common/index.d.ts +4 -4
- package/@types/common/with-schemas/index.d.ts +4 -4
- package/@types/index.d.ts +1 -1
- package/@types/persisters/persister-automerge/index.d.ts +1 -1
- package/@types/persisters/persister-automerge/with-schemas/index.d.ts +1 -1
- package/@types/persisters/persister-cr-sqlite-wasm/index.d.ts +1 -1
- package/@types/persisters/persister-cr-sqlite-wasm/with-schemas/index.d.ts +1 -1
- package/@types/persisters/persister-electric-sql/index.d.ts +4 -4
- package/@types/persisters/persister-electric-sql/with-schemas/index.d.ts +4 -4
- package/@types/persisters/persister-expo-sqlite/index.d.ts +1 -1
- package/@types/persisters/persister-expo-sqlite/with-schemas/index.d.ts +1 -1
- package/@types/persisters/persister-libsql/index.d.ts +1 -1
- package/@types/persisters/persister-libsql/with-schemas/index.d.ts +1 -1
- package/@types/persisters/persister-partykit-client/index.d.ts +1 -1
- package/@types/persisters/persister-partykit-client/with-schemas/index.d.ts +1 -1
- package/@types/persisters/persister-partykit-server/index.d.ts +7 -7
- package/@types/persisters/persister-partykit-server/with-schemas/index.d.ts +1 -1
- package/@types/persisters/persister-pglite/index.d.ts +1 -1
- package/@types/persisters/persister-pglite/with-schemas/index.d.ts +1 -1
- package/@types/persisters/persister-postgres/index.d.ts +1 -1
- package/@types/persisters/persister-postgres/with-schemas/index.d.ts +1 -1
- package/@types/persisters/persister-powersync/index.d.ts +1 -1
- package/@types/persisters/persister-powersync/with-schemas/index.d.ts +1 -1
- package/@types/persisters/persister-sqlite3/index.d.ts +1 -1
- package/@types/persisters/persister-sqlite3/with-schemas/index.d.ts +1 -1
- package/@types/persisters/persister-yjs/index.d.ts +1 -1
- package/@types/persisters/persister-yjs/with-schemas/index.d.ts +1 -1
- package/@types/synchronizers/synchronizer-ws-client/index.d.ts +1 -1
- package/@types/synchronizers/synchronizer-ws-client/with-schemas/index.d.ts +1 -1
- package/@types/synchronizers/synchronizer-ws-server/index.d.ts +1 -1
- package/@types/synchronizers/synchronizer-ws-server/with-schemas/index.d.ts +1 -1
- package/@types/synchronizers/synchronizer-ws-server-durable-object/index.d.ts +1 -1
- package/@types/synchronizers/synchronizer-ws-server-durable-object/with-schemas/index.d.ts +1 -1
- package/@types/ui-react/index.d.ts +3 -3
- package/@types/ui-react/with-schemas/index.d.ts +1 -1
- package/@types/ui-react-dom/index.d.ts +1 -1
- package/@types/ui-react-dom/with-schemas/index.d.ts +1 -1
- package/@types/ui-react-inspector/with-schemas/index.d.ts +1 -1
- package/@types/with-schemas/index.d.ts +1 -1
- package/index.js +1579 -1567
- package/indexes/index.js +15 -3
- package/indexes/with-schemas/index.js +15 -3
- package/min/index.js +1 -1
- package/min/index.js.gz +0 -0
- package/min/indexes/index.js +1 -1
- package/min/indexes/index.js.gz +0 -0
- package/min/indexes/with-schemas/index.js +1 -1
- package/min/indexes/with-schemas/index.js.gz +0 -0
- package/min/persisters/index.js +1 -1
- package/min/persisters/index.js.gz +0 -0
- package/min/persisters/with-schemas/index.js +1 -1
- package/min/persisters/with-schemas/index.js.gz +0 -0
- package/min/ui-react/index.js +1 -1
- package/min/ui-react/index.js.gz +0 -0
- package/min/ui-react/with-schemas/index.js +1 -1
- package/min/ui-react/with-schemas/index.js.gz +0 -0
- package/min/with-schemas/index.js +1 -1
- package/min/with-schemas/index.js.gz +0 -0
- package/package.json +7 -10
- package/persisters/index.js +95 -95
- package/persisters/with-schemas/index.js +95 -95
- package/readme.md +13 -13
- package/releases.md +25 -25
- package/synchronizers/synchronizer-ws-server-durable-object/index.js +1 -1
- package/synchronizers/synchronizer-ws-server-durable-object/with-schemas/index.js +1 -1
- package/ui-react/index.js +64 -53
- package/ui-react/with-schemas/index.js +64 -53
- package/ui-react-dom/index.js +3 -3
- package/ui-react-dom/with-schemas/index.js +3 -3
- package/ui-react-inspector/index.js +4 -4
- package/ui-react-inspector/with-schemas/index.js +4 -4
- package/with-schemas/index.js +1579 -1567
- package/@types/_internal/queries/index.d.cts +0 -0
- package/@types/_internal/queries/with-schemas/index.d.cts +0 -22
- package/@types/_internal/store/index.d.cts +0 -3
- package/@types/_internal/store/with-schemas/index.d.cts +0 -106
- package/@types/_internal/ui-react/index.d.cts +0 -0
- package/@types/_internal/ui-react/with-schemas/index.d.cts +0 -1130
- package/@types/checkpoints/index.d.cts +0 -1059
- package/@types/checkpoints/with-schemas/index.d.cts +0 -1151
- package/@types/common/index.d.cts +0 -158
- package/@types/common/with-schemas/index.d.cts +0 -158
- package/@types/index.d.cts +0 -17
- package/@types/indexes/index.d.cts +0 -1064
- package/@types/indexes/with-schemas/index.d.cts +0 -1210
- package/@types/mergeable-store/index.d.cts +0 -1139
- package/@types/mergeable-store/with-schemas/index.d.cts +0 -1628
- package/@types/metrics/index.d.cts +0 -917
- package/@types/metrics/with-schemas/index.d.cts +0 -1004
- package/@types/persisters/index.d.cts +0 -1877
- package/@types/persisters/persister-automerge/index.d.cts +0 -165
- package/@types/persisters/persister-automerge/with-schemas/index.d.cts +0 -180
- package/@types/persisters/persister-browser/index.d.cts +0 -185
- package/@types/persisters/persister-browser/with-schemas/index.d.cts +0 -208
- package/@types/persisters/persister-cr-sqlite-wasm/index.d.cts +0 -159
- package/@types/persisters/persister-cr-sqlite-wasm/with-schemas/index.d.cts +0 -178
- package/@types/persisters/persister-durable-object-storage/index.d.cts +0 -122
- package/@types/persisters/persister-durable-object-storage/with-schemas/index.d.cts +0 -136
- package/@types/persisters/persister-electric-sql/index.d.cts +0 -185
- package/@types/persisters/persister-electric-sql/with-schemas/index.d.cts +0 -204
- package/@types/persisters/persister-expo-sqlite/index.d.cts +0 -186
- package/@types/persisters/persister-expo-sqlite/with-schemas/index.d.cts +0 -205
- package/@types/persisters/persister-file/index.d.cts +0 -94
- package/@types/persisters/persister-file/with-schemas/index.d.cts +0 -107
- package/@types/persisters/persister-indexed-db/index.d.cts +0 -120
- package/@types/persisters/persister-indexed-db/with-schemas/index.d.cts +0 -135
- package/@types/persisters/persister-libsql/index.d.cts +0 -158
- package/@types/persisters/persister-libsql/with-schemas/index.d.cts +0 -177
- package/@types/persisters/persister-partykit-client/index.d.cts +0 -195
- package/@types/persisters/persister-partykit-client/with-schemas/index.d.cts +0 -210
- package/@types/persisters/persister-partykit-server/index.d.cts +0 -650
- package/@types/persisters/persister-partykit-server/with-schemas/index.d.cts +0 -695
- package/@types/persisters/persister-pglite/index.d.cts +0 -177
- package/@types/persisters/persister-pglite/with-schemas/index.d.cts +0 -196
- package/@types/persisters/persister-postgres/index.d.cts +0 -166
- package/@types/persisters/persister-postgres/with-schemas/index.d.cts +0 -185
- package/@types/persisters/persister-powersync/index.d.cts +0 -174
- package/@types/persisters/persister-powersync/with-schemas/index.d.cts +0 -193
- package/@types/persisters/persister-remote/index.d.cts +0 -117
- package/@types/persisters/persister-remote/with-schemas/index.d.cts +0 -133
- package/@types/persisters/persister-sqlite-wasm/index.d.cts +0 -175
- package/@types/persisters/persister-sqlite-wasm/with-schemas/index.d.cts +0 -195
- package/@types/persisters/persister-sqlite3/index.d.cts +0 -176
- package/@types/persisters/persister-sqlite3/with-schemas/index.d.cts +0 -195
- package/@types/persisters/persister-yjs/index.d.cts +0 -161
- package/@types/persisters/persister-yjs/with-schemas/index.d.cts +0 -176
- package/@types/persisters/with-schemas/index.d.cts +0 -2054
- package/@types/queries/index.d.cts +0 -3695
- package/@types/queries/with-schemas/index.d.cts +0 -4016
- package/@types/relationships/index.d.cts +0 -1320
- package/@types/relationships/with-schemas/index.d.cts +0 -1474
- package/@types/store/index.d.cts +0 -7598
- package/@types/store/with-schemas/index.d.cts +0 -9278
- package/@types/synchronizers/index.d.cts +0 -485
- package/@types/synchronizers/synchronizer-broadcast-channel/index.d.cts +0 -121
- package/@types/synchronizers/synchronizer-broadcast-channel/with-schemas/index.d.cts +0 -137
- package/@types/synchronizers/synchronizer-local/index.d.cts +0 -95
- package/@types/synchronizers/synchronizer-local/with-schemas/index.d.cts +0 -114
- package/@types/synchronizers/synchronizer-ws-client/index.d.cts +0 -160
- package/@types/synchronizers/synchronizer-ws-client/with-schemas/index.d.cts +0 -179
- package/@types/synchronizers/synchronizer-ws-server/index.d.cts +0 -736
- package/@types/synchronizers/synchronizer-ws-server/with-schemas/index.d.cts +0 -765
- package/@types/synchronizers/synchronizer-ws-server-durable-object/index.d.cts +0 -311
- package/@types/synchronizers/synchronizer-ws-server-durable-object/with-schemas/index.d.cts +0 -349
- package/@types/synchronizers/synchronizer-ws-server-simple/index.d.cts +0 -144
- package/@types/synchronizers/synchronizer-ws-server-simple/with-schemas/index.d.cts +0 -144
- package/@types/synchronizers/with-schemas/index.d.cts +0 -503
- package/@types/ui-react/index.d.cts +0 -16640
- package/@types/ui-react/with-schemas/index.d.cts +0 -17281
- package/@types/ui-react-dom/index.d.cts +0 -1862
- package/@types/ui-react-dom/with-schemas/index.d.cts +0 -1994
- package/@types/ui-react-inspector/index.d.cts +0 -79
- package/@types/ui-react-inspector/with-schemas/index.d.cts +0 -1985
- package/@types/with-schemas/index.d.cts +0 -17
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type {ComponentType, ReactElement} from 'react';
|
|
1
2
|
import type {Checkpoints} from '../../../checkpoints/with-schemas/index.d.ts';
|
|
2
3
|
import type {Callback, Id} from '../../../common/with-schemas/index.d.ts';
|
|
3
4
|
import type {Indexes} from '../../../indexes/with-schemas/index.d.ts';
|
|
@@ -18,7 +19,6 @@ import type {
|
|
|
18
19
|
TableIdFromSchema,
|
|
19
20
|
ValueIdFromSchema,
|
|
20
21
|
} from '../../store/with-schemas/index.d.ts';
|
|
21
|
-
import type {ComponentType, ReactElement} from 'react';
|
|
22
22
|
|
|
23
23
|
type StoreOrStoreId<Schemas extends OptionalSchemas> = Store<Schemas> | Id;
|
|
24
24
|
|
package/@types/common/index.d.ts
CHANGED
|
@@ -33,10 +33,10 @@ export type Ids = Id[];
|
|
|
33
33
|
export type Id = string;
|
|
34
34
|
|
|
35
35
|
/**
|
|
36
|
-
* The
|
|
37
|
-
* where the string should be considered to be the key of an objects
|
|
38
|
-
* Row Id string used in a Table), and typically `null` indicates a
|
|
39
|
-
* such as when used in the Store addRowListener method.
|
|
36
|
+
* The IdOrNull type is a simple alias for the union of a string or `null`
|
|
37
|
+
* value, where the string should be considered to be the key of an objects
|
|
38
|
+
* (such as a Row Id string used in a Table), and typically `null` indicates a
|
|
39
|
+
* wildcard - such as when used in the Store addRowListener method.
|
|
40
40
|
* @category Identity
|
|
41
41
|
* @since v1.0.0
|
|
42
42
|
*/
|
|
@@ -33,10 +33,10 @@ export type Ids = Id[];
|
|
|
33
33
|
export type Id = string;
|
|
34
34
|
|
|
35
35
|
/**
|
|
36
|
-
* The
|
|
37
|
-
* where the string should be considered to be the key of an objects
|
|
38
|
-
* Row Id string used in a Table), and typically `null` indicates a
|
|
39
|
-
* such as when used in the Store addRowListener method.
|
|
36
|
+
* The IdOrNull type is a simple alias for the union of a string or `null`
|
|
37
|
+
* value, where the string should be considered to be the key of an objects
|
|
38
|
+
* (such as a Row Id string used in a Table), and typically `null` indicates a
|
|
39
|
+
* wildcard - such as when used in the Store addRowListener method.
|
|
40
40
|
* @category Identity
|
|
41
41
|
* @since v1.0.0
|
|
42
42
|
*/
|
package/@types/index.d.ts
CHANGED
|
@@ -10,8 +10,8 @@
|
|
|
10
10
|
export * from './checkpoints/index.d.ts';
|
|
11
11
|
export * from './common/index.d.ts';
|
|
12
12
|
export * from './indexes/index.d.ts';
|
|
13
|
+
export * from './mergeable-store/index.d.ts';
|
|
13
14
|
export * from './metrics/index.d.ts';
|
|
14
15
|
export * from './queries/index.d.ts';
|
|
15
16
|
export * from './relationships/index.d.ts';
|
|
16
|
-
export * from './mergeable-store/index.d.ts';
|
|
17
17
|
export * from './store/index.d.ts';
|
|
@@ -10,9 +10,9 @@
|
|
|
10
10
|
* @module persister-automerge
|
|
11
11
|
* @since v4.0.0
|
|
12
12
|
*/
|
|
13
|
+
import type {DocHandle} from '@automerge/automerge-repo';
|
|
13
14
|
import type {Store} from '../../store/index.d.ts';
|
|
14
15
|
import type {Persister} from '../index.d.ts';
|
|
15
|
-
import type {DocHandle} from '@automerge/automerge-repo';
|
|
16
16
|
|
|
17
17
|
/**
|
|
18
18
|
* The AutomergePersister interface represents a Persister that lets you save
|
|
@@ -10,12 +10,12 @@
|
|
|
10
10
|
* @module persister-automerge
|
|
11
11
|
* @since v4.0.0
|
|
12
12
|
*/
|
|
13
|
+
import type {DocHandle} from '@automerge/automerge-repo';
|
|
13
14
|
import type {
|
|
14
15
|
OptionalSchemas,
|
|
15
16
|
Store,
|
|
16
17
|
} from '../../../store/with-schemas/index.d.ts';
|
|
17
18
|
import type {Persister} from '../../with-schemas/index.d.ts';
|
|
18
|
-
import type {DocHandle} from '@automerge/automerge-repo';
|
|
19
19
|
|
|
20
20
|
/**
|
|
21
21
|
* The AutomergePersister interface represents a Persister that lets you save
|
|
@@ -7,9 +7,9 @@
|
|
|
7
7
|
* @module persister-cr-sqlite-wasm
|
|
8
8
|
* @since v4.0.0
|
|
9
9
|
*/
|
|
10
|
+
import type {DB} from '@vlcn.io/crsqlite-wasm';
|
|
10
11
|
import type {Store} from '../../store/index.d.ts';
|
|
11
12
|
import type {DatabasePersisterConfig, Persister} from '../index.d.ts';
|
|
12
|
-
import type {DB} from '@vlcn.io/crsqlite-wasm';
|
|
13
13
|
|
|
14
14
|
/**
|
|
15
15
|
* The CrSqliteWasmPersister interface represents a Persister that lets you save
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
* @module persister-cr-sqlite-wasm
|
|
8
8
|
* @since v4.0.0
|
|
9
9
|
*/
|
|
10
|
+
import type {DB} from '@vlcn.io/crsqlite-wasm';
|
|
10
11
|
import type {
|
|
11
12
|
OptionalSchemas,
|
|
12
13
|
Store,
|
|
@@ -15,7 +16,6 @@ import type {
|
|
|
15
16
|
DatabasePersisterConfig,
|
|
16
17
|
Persister,
|
|
17
18
|
} from '../../with-schemas/index.d.ts';
|
|
18
|
-
import type {DB} from '@vlcn.io/crsqlite-wasm';
|
|
19
19
|
|
|
20
20
|
/**
|
|
21
21
|
* The CrSqliteWasmPersister interface represents a Persister that lets you save
|
|
@@ -7,9 +7,9 @@
|
|
|
7
7
|
* @module persister-electric-sql
|
|
8
8
|
* @since v4.6.0
|
|
9
9
|
*/
|
|
10
|
+
import type {ElectricClient} from 'electric-sql/client/model';
|
|
10
11
|
import type {Store} from '../../store/index.d.ts';
|
|
11
12
|
import type {DatabasePersisterConfig, Persister} from '../index.d.ts';
|
|
12
|
-
import type {ElectricClient} from 'electric-sql/client/model';
|
|
13
13
|
|
|
14
14
|
/**
|
|
15
15
|
* The ElectricSqlPersister interface represents a Persister that lets you save
|
|
@@ -34,10 +34,10 @@ export interface ElectricSqlPersister extends Persister {
|
|
|
34
34
|
* then gets the Electric client back out again.
|
|
35
35
|
*
|
|
36
36
|
* ```js yolo
|
|
37
|
-
* import {schema} from './generated/client';
|
|
38
37
|
* import {ElectricDatabase, electrify} from 'electric-sql/wa-sqlite';
|
|
39
38
|
* import {createStore} from 'tinybase';
|
|
40
39
|
* import {createElectricSqlPersister} from 'tinybase/persisters/persister-electric-sql';
|
|
40
|
+
* import {schema} from './generated/client';
|
|
41
41
|
*
|
|
42
42
|
* const electricClient = await electrify(
|
|
43
43
|
* await ElectricDatabase.init('electric.db', ''),
|
|
@@ -103,10 +103,10 @@ export interface ElectricSqlPersister extends Persister {
|
|
|
103
103
|
* into the Store.
|
|
104
104
|
*
|
|
105
105
|
* ```js yolo
|
|
106
|
-
* import {schema} from './generated/client';
|
|
107
106
|
* import {ElectricDatabase, electrify} from 'electric-sql/wa-sqlite';
|
|
108
107
|
* import {createStore} from 'tinybase';
|
|
109
108
|
* import {createElectricSqlPersister} from 'tinybase/persisters/persister-electric-sql';
|
|
109
|
+
* import {schema} from './generated/client';
|
|
110
110
|
*
|
|
111
111
|
* const electricClient = await electrify(
|
|
112
112
|
* await ElectricDatabase.init('electric.db', ''),
|
|
@@ -144,10 +144,10 @@ export interface ElectricSqlPersister extends Persister {
|
|
|
144
144
|
* a local ElectricSql database with tabular mapping.
|
|
145
145
|
*
|
|
146
146
|
* ```js yolo
|
|
147
|
-
* import {schema} from './generated/client';
|
|
148
147
|
* import {ElectricDatabase, electrify} from 'electric-sql/wa-sqlite';
|
|
149
148
|
* import {createStore} from 'tinybase';
|
|
150
149
|
* import {createElectricSqlPersister} from 'tinybase/persisters/persister-electric-sql';
|
|
150
|
+
* import {schema} from './generated/client';
|
|
151
151
|
*
|
|
152
152
|
* const electricClient = await electrify(
|
|
153
153
|
* await ElectricDatabase.init('electric.db', ''),
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
* @module persister-electric-sql
|
|
8
8
|
* @since v4.6.0
|
|
9
9
|
*/
|
|
10
|
+
import type {ElectricClient} from 'electric-sql/client/model';
|
|
10
11
|
import type {
|
|
11
12
|
OptionalSchemas,
|
|
12
13
|
Store,
|
|
@@ -15,7 +16,6 @@ import type {
|
|
|
15
16
|
DatabasePersisterConfig,
|
|
16
17
|
Persister,
|
|
17
18
|
} from '../../with-schemas/index.d.ts';
|
|
18
|
-
import type {ElectricClient} from 'electric-sql/client/model';
|
|
19
19
|
|
|
20
20
|
/**
|
|
21
21
|
* The ElectricSqlPersister interface represents a Persister that lets you save
|
|
@@ -41,10 +41,10 @@ export interface ElectricSqlPersister<Schemas extends OptionalSchemas>
|
|
|
41
41
|
* then gets the Electric client back out again.
|
|
42
42
|
*
|
|
43
43
|
* ```js yolo
|
|
44
|
-
* import {schema} from './generated/client';
|
|
45
44
|
* import {ElectricDatabase, electrify} from 'electric-sql/wa-sqlite';
|
|
46
45
|
* import {createStore} from 'tinybase';
|
|
47
46
|
* import {createElectricSqlPersister} from 'tinybase/persisters/persister-electric-sql';
|
|
47
|
+
* import {schema} from './generated/client';
|
|
48
48
|
*
|
|
49
49
|
* const electricClient = await electrify(
|
|
50
50
|
* await ElectricDatabase.init('electric.db', ''),
|
|
@@ -122,10 +122,10 @@ export interface ElectricSqlPersister<Schemas extends OptionalSchemas>
|
|
|
122
122
|
* into the Store.
|
|
123
123
|
*
|
|
124
124
|
* ```js yolo
|
|
125
|
-
* import {schema} from './generated/client';
|
|
126
125
|
* import {ElectricDatabase, electrify} from 'electric-sql/wa-sqlite';
|
|
127
126
|
* import {createStore} from 'tinybase';
|
|
128
127
|
* import {createElectricSqlPersister} from 'tinybase/persisters/persister-electric-sql';
|
|
128
|
+
* import {schema} from './generated/client';
|
|
129
129
|
*
|
|
130
130
|
* const electricClient = await electrify(
|
|
131
131
|
* await ElectricDatabase.init('electric.db', ''),
|
|
@@ -163,10 +163,10 @@ export interface ElectricSqlPersister<Schemas extends OptionalSchemas>
|
|
|
163
163
|
* a local ElectricSql database with tabular mapping.
|
|
164
164
|
*
|
|
165
165
|
* ```js yolo
|
|
166
|
-
* import {schema} from './generated/client';
|
|
167
166
|
* import {ElectricDatabase, electrify} from 'electric-sql/wa-sqlite';
|
|
168
167
|
* import {createStore} from 'tinybase';
|
|
169
168
|
* import {createElectricSqlPersister} from 'tinybase/persisters/persister-electric-sql';
|
|
169
|
+
* import {schema} from './generated/client';
|
|
170
170
|
*
|
|
171
171
|
* const electricClient = await electrify(
|
|
172
172
|
* await ElectricDatabase.init('electric.db', ''),
|
|
@@ -14,10 +14,10 @@
|
|
|
14
14
|
* @module persister-expo-sqlite
|
|
15
15
|
* @since v4.5.0
|
|
16
16
|
*/
|
|
17
|
+
import type {SQLiteDatabase} from 'expo-sqlite';
|
|
17
18
|
import type {MergeableStore} from '../../mergeable-store/index.d.ts';
|
|
18
19
|
import type {Store} from '../../store/index.d.ts';
|
|
19
20
|
import type {DatabasePersisterConfig, Persister, Persists} from '../index.d.ts';
|
|
20
|
-
import type {SQLiteDatabase} from 'expo-sqlite';
|
|
21
21
|
|
|
22
22
|
/**
|
|
23
23
|
* The ExpoSqlitePersister interface represents a Persister that lets you save
|
|
@@ -14,6 +14,7 @@
|
|
|
14
14
|
* @module persister-expo-sqlite
|
|
15
15
|
* @since v4.5.0
|
|
16
16
|
*/
|
|
17
|
+
import type {SQLiteDatabase} from 'expo-sqlite';
|
|
17
18
|
import type {MergeableStore} from '../../../mergeable-store/with-schemas/index.d.ts';
|
|
18
19
|
import type {
|
|
19
20
|
OptionalSchemas,
|
|
@@ -24,7 +25,6 @@ import type {
|
|
|
24
25
|
Persister,
|
|
25
26
|
Persists,
|
|
26
27
|
} from '../../with-schemas/index.d.ts';
|
|
27
|
-
import type {SQLiteDatabase} from 'expo-sqlite';
|
|
28
28
|
|
|
29
29
|
/**
|
|
30
30
|
* The ExpoSqlitePersister interface represents a Persister that lets you save
|
|
@@ -7,9 +7,9 @@
|
|
|
7
7
|
* @module persister-libsql
|
|
8
8
|
* @since v4.7.0
|
|
9
9
|
*/
|
|
10
|
+
import type {Client} from '@libsql/client';
|
|
10
11
|
import type {Store} from '../../store/index.d.ts';
|
|
11
12
|
import type {DatabasePersisterConfig, Persister} from '../index.d.ts';
|
|
12
|
-
import type {Client} from '@libsql/client';
|
|
13
13
|
|
|
14
14
|
/**
|
|
15
15
|
* The LibSqlPersister interface represents a Persister that lets you save and
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
* @module persister-libsql
|
|
8
8
|
* @since v4.7.0
|
|
9
9
|
*/
|
|
10
|
+
import type {Client} from '@libsql/client';
|
|
10
11
|
import type {
|
|
11
12
|
OptionalSchemas,
|
|
12
13
|
Store,
|
|
@@ -15,7 +16,6 @@ import type {
|
|
|
15
16
|
DatabasePersisterConfig,
|
|
16
17
|
Persister,
|
|
17
18
|
} from '../../with-schemas/index.d.ts';
|
|
18
|
-
import type {Client} from '@libsql/client';
|
|
19
19
|
|
|
20
20
|
/**
|
|
21
21
|
* The LibSqlPersister interface represents a Persister that lets you save and
|
|
@@ -17,9 +17,9 @@
|
|
|
17
17
|
* @module persister-partykit-client
|
|
18
18
|
* @since v4.3.0
|
|
19
19
|
*/
|
|
20
|
+
import type {PartySocket} from 'partysocket';
|
|
20
21
|
import type {Store} from '../../store/index.d.ts';
|
|
21
22
|
import type {Persister} from '../index.d.ts';
|
|
22
|
-
import type {PartySocket} from 'partysocket';
|
|
23
23
|
|
|
24
24
|
/**
|
|
25
25
|
* The PartyKitPersister interface represents a Persister that lets you save and
|
|
@@ -17,12 +17,12 @@
|
|
|
17
17
|
* @module persister-partykit-client
|
|
18
18
|
* @since v4.3.0
|
|
19
19
|
*/
|
|
20
|
+
import type {PartySocket} from 'partysocket';
|
|
20
21
|
import type {
|
|
21
22
|
OptionalSchemas,
|
|
22
23
|
Store,
|
|
23
24
|
} from '../../../store/with-schemas/index.d.ts';
|
|
24
25
|
import type {Persister} from '../../with-schemas/index.d.ts';
|
|
25
|
-
import type {PartySocket} from 'partysocket';
|
|
26
26
|
|
|
27
27
|
/**
|
|
28
28
|
* The PartyKitPersister interface represents a Persister that lets you save and
|
|
@@ -16,6 +16,13 @@
|
|
|
16
16
|
* @module persister-partykit-server
|
|
17
17
|
* @since v4.3.0
|
|
18
18
|
*/
|
|
19
|
+
import type {
|
|
20
|
+
Connection,
|
|
21
|
+
Party,
|
|
22
|
+
Request,
|
|
23
|
+
Server,
|
|
24
|
+
Storage,
|
|
25
|
+
} from 'partykit/server';
|
|
19
26
|
import type {Id} from '../../common/index.d.ts';
|
|
20
27
|
import type {
|
|
21
28
|
Cell,
|
|
@@ -25,13 +32,6 @@ import type {
|
|
|
25
32
|
Value,
|
|
26
33
|
ValueOrUndefined,
|
|
27
34
|
} from '../../store/index.d.ts';
|
|
28
|
-
import type {
|
|
29
|
-
Connection,
|
|
30
|
-
Party,
|
|
31
|
-
Request,
|
|
32
|
-
Server,
|
|
33
|
-
Storage,
|
|
34
|
-
} from 'partykit/server';
|
|
35
35
|
|
|
36
36
|
/**
|
|
37
37
|
* The TinyBasePartyKitServerConfig type describes the configuration of a
|
|
@@ -16,6 +16,7 @@
|
|
|
16
16
|
* @module persister-partykit-server
|
|
17
17
|
* @since v4.3.0
|
|
18
18
|
*/
|
|
19
|
+
import type {Connection, Party, Request, Server} from 'partykit/server';
|
|
19
20
|
import type {Id} from '../../../common/with-schemas/index.d.ts';
|
|
20
21
|
import type {
|
|
21
22
|
Cell,
|
|
@@ -28,7 +29,6 @@ import type {
|
|
|
28
29
|
Value,
|
|
29
30
|
ValueOrUndefined,
|
|
30
31
|
} from '../../../store/with-schemas/index.d.ts';
|
|
31
|
-
import type {Connection, Party, Request, Server} from 'partykit/server';
|
|
32
32
|
|
|
33
33
|
/**
|
|
34
34
|
* The TinyBasePartyKitServerConfig type describes the configuration of a
|
|
@@ -6,10 +6,10 @@
|
|
|
6
6
|
* @module persister-pglite
|
|
7
7
|
* @since 5.2.0
|
|
8
8
|
*/
|
|
9
|
+
import type {PGlite} from '@electric-sql/pglite';
|
|
9
10
|
import type {MergeableStore} from '../../mergeable-store/index.d.ts';
|
|
10
11
|
import type {Store} from '../../store/index.d.ts';
|
|
11
12
|
import type {DatabasePersisterConfig, Persister, Persists} from '../index.d.ts';
|
|
12
|
-
import type {PGlite} from '@electric-sql/pglite';
|
|
13
13
|
|
|
14
14
|
/**
|
|
15
15
|
* The PglitePersister interface represents a Persister that lets you save and
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
* @module persister-pglite
|
|
7
7
|
* @since 5.2.0
|
|
8
8
|
*/
|
|
9
|
+
import type {PGlite} from '@electric-sql/pglite';
|
|
9
10
|
import type {MergeableStore} from '../../../mergeable-store/with-schemas/index.d.ts';
|
|
10
11
|
import type {
|
|
11
12
|
OptionalSchemas,
|
|
@@ -16,7 +17,6 @@ import type {
|
|
|
16
17
|
Persister,
|
|
17
18
|
Persists,
|
|
18
19
|
} from '../../with-schemas/index.d.ts';
|
|
19
|
-
import type {PGlite} from '@electric-sql/pglite';
|
|
20
20
|
|
|
21
21
|
/**
|
|
22
22
|
* The PglitePersister interface represents a Persister that lets you save and
|
|
@@ -6,10 +6,10 @@
|
|
|
6
6
|
* @module persister-postgres
|
|
7
7
|
* @since 5.2.0
|
|
8
8
|
*/
|
|
9
|
+
import type {Sql} from 'postgres';
|
|
9
10
|
import type {MergeableStore} from '../../mergeable-store/index.d.ts';
|
|
10
11
|
import type {Store} from '../../store/index.d.ts';
|
|
11
12
|
import type {DatabasePersisterConfig, Persister, Persists} from '../index.d.ts';
|
|
12
|
-
import type {Sql} from 'postgres';
|
|
13
13
|
|
|
14
14
|
/**
|
|
15
15
|
* The PostgresPersister interface represents a Persister that lets you save and
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
* @module persister-postgres
|
|
7
7
|
* @since 5.2.0
|
|
8
8
|
*/
|
|
9
|
+
import type {Sql} from 'postgres';
|
|
9
10
|
import type {MergeableStore} from '../../../mergeable-store/with-schemas/index.d.ts';
|
|
10
11
|
import type {
|
|
11
12
|
OptionalSchemas,
|
|
@@ -16,7 +17,6 @@ import type {
|
|
|
16
17
|
Persister,
|
|
17
18
|
Persists,
|
|
18
19
|
} from '../../with-schemas/index.d.ts';
|
|
19
|
-
import type {Sql} from 'postgres';
|
|
20
20
|
|
|
21
21
|
/**
|
|
22
22
|
* The PostgresPersister interface represents a Persister that lets you save and
|
|
@@ -7,9 +7,9 @@
|
|
|
7
7
|
* @module persister-powersync
|
|
8
8
|
* @since v4.8.0
|
|
9
9
|
*/
|
|
10
|
+
import type {AbstractPowerSyncDatabase} from '@powersync/common';
|
|
10
11
|
import type {Store} from '../../store/index.d.ts';
|
|
11
12
|
import type {DatabasePersisterConfig, Persister} from '../index.d.ts';
|
|
12
|
-
import type {AbstractPowerSyncDatabase} from '@powersync/common';
|
|
13
13
|
|
|
14
14
|
/**
|
|
15
15
|
* The PowerSyncPersister interface represents a Persister that lets you save
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
* @module persister-powersync
|
|
8
8
|
* @since v4.8.0
|
|
9
9
|
*/
|
|
10
|
+
import type {AbstractPowerSyncDatabase} from '@powersync/common';
|
|
10
11
|
import type {
|
|
11
12
|
OptionalSchemas,
|
|
12
13
|
Store,
|
|
@@ -15,7 +16,6 @@ import type {
|
|
|
15
16
|
DatabasePersisterConfig,
|
|
16
17
|
Persister,
|
|
17
18
|
} from '../../with-schemas/index.d.ts';
|
|
18
|
-
import type {AbstractPowerSyncDatabase} from '@powersync/common';
|
|
19
19
|
|
|
20
20
|
/**
|
|
21
21
|
* The PowerSyncPersister interface represents a Persister that lets you save
|
|
@@ -7,10 +7,10 @@
|
|
|
7
7
|
* @module persister-sqlite3
|
|
8
8
|
* @since v4.0.0
|
|
9
9
|
*/
|
|
10
|
+
import type {Database} from 'sqlite3';
|
|
10
11
|
import type {MergeableStore} from '../../mergeable-store/index.d.ts';
|
|
11
12
|
import type {Store} from '../../store/index.d.ts';
|
|
12
13
|
import type {DatabasePersisterConfig, Persister, Persists} from '../index.d.ts';
|
|
13
|
-
import type {Database} from 'sqlite3';
|
|
14
14
|
|
|
15
15
|
/**
|
|
16
16
|
* The Sqlite3Persister interface represents a Persister that lets you save and
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
* @module persister-sqlite3
|
|
8
8
|
* @since v4.0.0
|
|
9
9
|
*/
|
|
10
|
+
import type {Database} from 'sqlite3';
|
|
10
11
|
import type {MergeableStore} from '../../../mergeable-store/with-schemas/index.d.ts';
|
|
11
12
|
import type {
|
|
12
13
|
OptionalSchemas,
|
|
@@ -17,7 +18,6 @@ import type {
|
|
|
17
18
|
Persister,
|
|
18
19
|
Persists,
|
|
19
20
|
} from '../../with-schemas/index.d.ts';
|
|
20
|
-
import type {Database} from 'sqlite3';
|
|
21
21
|
|
|
22
22
|
/**
|
|
23
23
|
* The Sqlite3Persister interface represents a Persister that lets you save and
|
|
@@ -10,9 +10,9 @@
|
|
|
10
10
|
* @module persister-yjs
|
|
11
11
|
* @since v4.0.0
|
|
12
12
|
*/
|
|
13
|
+
import type {Doc as YDoc} from 'yjs';
|
|
13
14
|
import type {Store} from '../../store/index.d.ts';
|
|
14
15
|
import type {Persister} from '../index.d.ts';
|
|
15
|
-
import type {Doc as YDoc} from 'yjs';
|
|
16
16
|
|
|
17
17
|
/**
|
|
18
18
|
* The YjsPersister interface represents a Persister that lets you save and load
|
|
@@ -10,12 +10,12 @@
|
|
|
10
10
|
* @module persister-yjs
|
|
11
11
|
* @since v4.0.0
|
|
12
12
|
*/
|
|
13
|
+
import type {Doc as YDoc} from 'yjs';
|
|
13
14
|
import type {
|
|
14
15
|
OptionalSchemas,
|
|
15
16
|
Store,
|
|
16
17
|
} from '../../../store/with-schemas/index.d.ts';
|
|
17
18
|
import type {Persister} from '../../with-schemas/index.d.ts';
|
|
18
|
-
import type {Doc as YDoc} from 'yjs';
|
|
19
19
|
|
|
20
20
|
/**
|
|
21
21
|
* The YjsPersister interface represents a Persister that lets you save and load
|
|
@@ -8,9 +8,9 @@
|
|
|
8
8
|
* @module synchronizer-ws-client
|
|
9
9
|
* @since v5.0.0
|
|
10
10
|
*/
|
|
11
|
+
import type {WebSocket as WsWebSocket} from 'ws';
|
|
11
12
|
import type {MergeableStore} from '../../mergeable-store/index.d.ts';
|
|
12
13
|
import type {Receive, Send, Synchronizer} from '../index.d.ts';
|
|
13
|
-
import type {WebSocket as WsWebSocket} from 'ws';
|
|
14
14
|
|
|
15
15
|
/**
|
|
16
16
|
* The WebSocketTypes type represents the valid types of WebSocket that can be
|
|
@@ -8,10 +8,10 @@
|
|
|
8
8
|
* @module synchronizer-ws-client
|
|
9
9
|
* @since v5.0.0
|
|
10
10
|
*/
|
|
11
|
+
import type {WebSocket as WsWebSocket} from 'ws';
|
|
11
12
|
import type {MergeableStore} from '../../../mergeable-store/with-schemas/index.d.ts';
|
|
12
13
|
import type {OptionalSchemas} from '../../../store/with-schemas/index.d.ts';
|
|
13
14
|
import type {Receive, Send, Synchronizer} from '../../with-schemas/index.d.ts';
|
|
14
|
-
import type {WebSocket as WsWebSocket} from 'ws';
|
|
15
15
|
|
|
16
16
|
/**
|
|
17
17
|
* The WebSocketTypes type represents the valid types of WebSocket that can be
|
|
@@ -7,11 +7,11 @@
|
|
|
7
7
|
* @module synchronizer-ws-server
|
|
8
8
|
* @since v5.0.0
|
|
9
9
|
*/
|
|
10
|
+
import type {WebSocketServer} from 'ws';
|
|
10
11
|
import type {Id, IdOrNull, Ids} from '../../common/index.d.ts';
|
|
11
12
|
import type {MergeableStore} from '../../mergeable-store/index.d.ts';
|
|
12
13
|
import type {Persister, Persists} from '../../persisters/index.d.ts';
|
|
13
14
|
import type {IdAddedOrRemoved} from '../../store/index.d.ts';
|
|
14
|
-
import type {WebSocketServer} from 'ws';
|
|
15
15
|
|
|
16
16
|
/**
|
|
17
17
|
* The PathIdsListener type describes a function that is used to listen to
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
* @module synchronizer-ws-server
|
|
8
8
|
* @since v5.0.0
|
|
9
9
|
*/
|
|
10
|
+
import type {WebSocketServer} from 'ws';
|
|
10
11
|
import type {Id, IdOrNull, Ids} from '../../../common/with-schemas/index.d.ts';
|
|
11
12
|
import type {MergeableStore} from '../../../mergeable-store/with-schemas/index.d.ts';
|
|
12
13
|
import type {
|
|
@@ -17,7 +18,6 @@ import type {
|
|
|
17
18
|
IdAddedOrRemoved,
|
|
18
19
|
OptionalSchemas,
|
|
19
20
|
} from '../../../store/with-schemas/index.d.ts';
|
|
20
|
-
import type {WebSocketServer} from 'ws';
|
|
21
21
|
|
|
22
22
|
/**
|
|
23
23
|
* The PathIdsListener type describes a function that is used to listen to
|
|
@@ -9,9 +9,9 @@
|
|
|
9
9
|
* @module synchronizer-ws-server-durable-object
|
|
10
10
|
* @since v5.4.0
|
|
11
11
|
*/
|
|
12
|
+
import {DurableObject} from 'cloudflare:workers';
|
|
12
13
|
import type {Id, IdAddedOrRemoved, Ids} from '../../index.d.ts';
|
|
13
14
|
import type {Persister, Persists} from '../../persisters/index.d.ts';
|
|
14
|
-
import {DurableObject} from 'cloudflare:workers';
|
|
15
15
|
|
|
16
16
|
/**
|
|
17
17
|
* A WsServerDurableObject is the server component (running as a Cloudflare
|
|
@@ -9,6 +9,7 @@
|
|
|
9
9
|
* @module synchronizer-ws-server-durable-object
|
|
10
10
|
* @since v5.4.0
|
|
11
11
|
*/
|
|
12
|
+
import {DurableObject} from 'cloudflare:workers';
|
|
12
13
|
import type {
|
|
13
14
|
Persister,
|
|
14
15
|
Persists,
|
|
@@ -19,7 +20,6 @@ import type {
|
|
|
19
20
|
Ids,
|
|
20
21
|
OptionalSchemas,
|
|
21
22
|
} from '../../../with-schemas/index.d.ts';
|
|
22
|
-
import {DurableObject} from 'cloudflare:workers';
|
|
23
23
|
|
|
24
24
|
/**
|
|
25
25
|
* A WsServerDurableObject is the server component (running as a Cloudflare
|
|
@@ -22,6 +22,7 @@
|
|
|
22
22
|
* @module ui-react
|
|
23
23
|
* @since v1.0.0
|
|
24
24
|
*/
|
|
25
|
+
import type {ComponentType, ReactElement} from 'react';
|
|
25
26
|
import type {
|
|
26
27
|
CheckpointIds,
|
|
27
28
|
CheckpointIdsListener,
|
|
@@ -102,7 +103,6 @@ import type {
|
|
|
102
103
|
ValuesListener,
|
|
103
104
|
} from '../store/index.d.ts';
|
|
104
105
|
import type {Synchronizer} from '../synchronizers/index.d.ts';
|
|
105
|
-
import type {ComponentType, ReactElement} from 'react';
|
|
106
106
|
|
|
107
107
|
/**
|
|
108
108
|
* The StoreOrStoreId type is used when you need to refer to a Store in a React
|
|
@@ -11815,7 +11815,7 @@ export function usePersisterOrPersisterById(
|
|
|
11815
11815
|
// useProvidePersister
|
|
11816
11816
|
export function useProvidePersister(
|
|
11817
11817
|
persisterId: Id,
|
|
11818
|
-
persister: AnyPersister
|
|
11818
|
+
persister: AnyPersister,
|
|
11819
11819
|
): void;
|
|
11820
11820
|
|
|
11821
11821
|
/**
|
|
@@ -12318,7 +12318,7 @@ export function useSynchronizerOrSynchronizerById(
|
|
|
12318
12318
|
// useProvideSynchronizer
|
|
12319
12319
|
export function useProvideSynchronizer(
|
|
12320
12320
|
synchronizerId: Id,
|
|
12321
|
-
synchronizer: Synchronizer
|
|
12321
|
+
synchronizer: Synchronizer,
|
|
12322
12322
|
): void;
|
|
12323
12323
|
|
|
12324
12324
|
/**
|
|
@@ -22,6 +22,7 @@
|
|
|
22
22
|
* @module ui-react
|
|
23
23
|
* @since v1.0.0
|
|
24
24
|
*/
|
|
25
|
+
import type {ReactElement} from 'react';
|
|
25
26
|
import type {
|
|
26
27
|
AllCellIdFromSchema,
|
|
27
28
|
CellIdFromSchema,
|
|
@@ -152,7 +153,6 @@ import type {
|
|
|
152
153
|
ValuesListener,
|
|
153
154
|
} from '../../store/with-schemas/index.d.ts';
|
|
154
155
|
import type {Synchronizer} from '../../synchronizers/with-schemas/index.d.ts';
|
|
155
|
-
import type {ReactElement} from 'react';
|
|
156
156
|
|
|
157
157
|
export type WithSchemas<Schemas extends OptionalSchemas> = {
|
|
158
158
|
/**
|
|
@@ -10,6 +10,7 @@
|
|
|
10
10
|
* @module ui-react-dom
|
|
11
11
|
* @since v4.1.0
|
|
12
12
|
*/
|
|
13
|
+
import type {ComponentType} from 'react';
|
|
13
14
|
import type {Id, Ids} from '../common/index.d.ts';
|
|
14
15
|
import type {
|
|
15
16
|
CellProps,
|
|
@@ -22,7 +23,6 @@ import type {
|
|
|
22
23
|
StoreOrStoreId,
|
|
23
24
|
ValueProps,
|
|
24
25
|
} from '../ui-react/index.d.ts';
|
|
25
|
-
import type {ComponentType} from 'react';
|
|
26
26
|
|
|
27
27
|
/**
|
|
28
28
|
* The CustomCell object is used to configure custom cell rendering in an HTML
|
|
@@ -10,6 +10,7 @@
|
|
|
10
10
|
* @module ui-react-dom
|
|
11
11
|
* @since v4.1.0
|
|
12
12
|
*/
|
|
13
|
+
import type {ComponentType} from 'react';
|
|
13
14
|
import type {
|
|
14
15
|
CellIdFromSchema,
|
|
15
16
|
TableIdFromSchema,
|
|
@@ -29,7 +30,6 @@ import type {
|
|
|
29
30
|
import type {Id, Ids} from '../../common/with-schemas/index.d.ts';
|
|
30
31
|
import type {NoSchemas} from '../../store/index.d.ts';
|
|
31
32
|
import type {OptionalSchemas} from '../../store/with-schemas/index.d.ts';
|
|
32
|
-
import type {ComponentType} from 'react';
|
|
33
33
|
|
|
34
34
|
/**
|
|
35
35
|
* The CustomCell object is used to configure custom cell rendering in an HTML
|