@pluv/addon-indexeddb 0.15.0 → 0.16.0
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/.turbo/turbo-build.log +7 -7
- package/CHANGELOG.md +8 -0
- package/dist/index.d.mts +4 -3
- package/dist/index.d.ts +4 -3
- package/package.json +8 -7
- package/src/IndexedDBStorage.ts +2 -1
- package/src/addonIndexedDB.ts +4 -3
package/.turbo/turbo-build.log
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
|
|
2
|
-
> @pluv/addon-indexeddb@0.
|
|
2
|
+
> @pluv/addon-indexeddb@0.16.0 build /home/runner/work/pluv/pluv/packages/addon-indexeddb
|
|
3
3
|
> tsup src/index.ts --format esm,cjs --dts
|
|
4
4
|
|
|
5
5
|
[34mCLI[39m Building entry: src/index.ts
|
|
6
6
|
[34mCLI[39m Using tsconfig: tsconfig.json
|
|
7
|
-
[34mCLI[39m tsup v8.0.
|
|
7
|
+
[34mCLI[39m tsup v8.0.2
|
|
8
8
|
[34mCLI[39m Target: es6
|
|
9
9
|
[34mESM[39m Build start
|
|
10
10
|
[34mCJS[39m Build start
|
|
11
11
|
[32mESM[39m [1mdist/index.mjs [22m[32m3.84 KB[39m
|
|
12
|
-
[32mESM[39m ⚡️ Build success in
|
|
12
|
+
[32mESM[39m ⚡️ Build success in 99ms
|
|
13
13
|
[32mCJS[39m [1mdist/index.js [22m[32m4.87 KB[39m
|
|
14
|
-
[32mCJS[39m ⚡️ Build success in
|
|
14
|
+
[32mCJS[39m ⚡️ Build success in 99ms
|
|
15
15
|
[34mDTS[39m Build start
|
|
16
|
-
[32mDTS[39m ⚡️ Build success in
|
|
17
|
-
[32mDTS[39m [1mdist/index.d.mts [22m[
|
|
18
|
-
[32mDTS[39m [1mdist/index.d.ts [22m[
|
|
16
|
+
[32mDTS[39m ⚡️ Build success in 3341ms
|
|
17
|
+
[32mDTS[39m [1mdist/index.d.mts [22m[32m779.00 B[39m
|
|
18
|
+
[32mDTS[39m [1mdist/index.d.ts [22m[32m779.00 B[39m
|
package/CHANGELOG.md
CHANGED
package/dist/index.d.mts
CHANGED
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import * as _pluv_types from '@pluv/types';
|
|
2
2
|
import { IOLike, JsonObject } from '@pluv/types';
|
|
3
|
-
import {
|
|
3
|
+
import { PluvRoomAddon, PluvRoom } from '@pluv/client';
|
|
4
|
+
import { AbstractCrdtType } from '@pluv/crdt';
|
|
4
5
|
|
|
5
|
-
interface AddonIndexedDBConfig<TIO extends IOLike, TPresence extends JsonObject = {}, TStorage extends Record<string,
|
|
6
|
+
interface AddonIndexedDBConfig<TIO extends IOLike, TPresence extends JsonObject = {}, TStorage extends Record<string, AbstractCrdtType<any, any>> = {}> {
|
|
6
7
|
enabled?: boolean | ((room: PluvRoom<TIO, TPresence, TStorage>) => boolean);
|
|
7
8
|
}
|
|
8
|
-
declare const addonIndexedDB: <TIO extends IOLike<_pluv_types.IOAuthorize<any, any>, {}, {}, {}, {}>, TPresence extends JsonObject = {}, TStorage extends Record<string,
|
|
9
|
+
declare const addonIndexedDB: <TIO extends IOLike<_pluv_types.IOAuthorize<any, any>, {}, {}, {}, {}>, TPresence extends JsonObject = {}, TStorage extends Record<string, AbstractCrdtType<any, any>> = {}>(config?: AddonIndexedDBConfig<TIO, TPresence, TStorage> | undefined) => PluvRoomAddon<TIO, TPresence, TStorage>;
|
|
9
10
|
|
|
10
11
|
export { addonIndexedDB };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import * as _pluv_types from '@pluv/types';
|
|
2
2
|
import { IOLike, JsonObject } from '@pluv/types';
|
|
3
|
-
import {
|
|
3
|
+
import { PluvRoomAddon, PluvRoom } from '@pluv/client';
|
|
4
|
+
import { AbstractCrdtType } from '@pluv/crdt';
|
|
4
5
|
|
|
5
|
-
interface AddonIndexedDBConfig<TIO extends IOLike, TPresence extends JsonObject = {}, TStorage extends Record<string,
|
|
6
|
+
interface AddonIndexedDBConfig<TIO extends IOLike, TPresence extends JsonObject = {}, TStorage extends Record<string, AbstractCrdtType<any, any>> = {}> {
|
|
6
7
|
enabled?: boolean | ((room: PluvRoom<TIO, TPresence, TStorage>) => boolean);
|
|
7
8
|
}
|
|
8
|
-
declare const addonIndexedDB: <TIO extends IOLike<_pluv_types.IOAuthorize<any, any>, {}, {}, {}, {}>, TPresence extends JsonObject = {}, TStorage extends Record<string,
|
|
9
|
+
declare const addonIndexedDB: <TIO extends IOLike<_pluv_types.IOAuthorize<any, any>, {}, {}, {}, {}>, TPresence extends JsonObject = {}, TStorage extends Record<string, AbstractCrdtType<any, any>> = {}>(config?: AddonIndexedDBConfig<TIO, TPresence, TStorage> | undefined) => PluvRoomAddon<TIO, TPresence, TStorage>;
|
|
9
10
|
|
|
10
11
|
export { addonIndexedDB };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pluv/addon-indexeddb",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.16.0",
|
|
4
4
|
"description": "@pluv/io indexeddb for client storage persistance",
|
|
5
5
|
"author": "leedavidcs",
|
|
6
6
|
"license": "MIT",
|
|
@@ -18,15 +18,16 @@
|
|
|
18
18
|
},
|
|
19
19
|
"dependencies": {
|
|
20
20
|
"idb": "^8.0.0",
|
|
21
|
-
"@pluv/client": "^0.
|
|
21
|
+
"@pluv/client": "^0.16.0",
|
|
22
|
+
"@pluv/crdt": "^0.16.0"
|
|
22
23
|
},
|
|
23
24
|
"devDependencies": {
|
|
24
25
|
"eslint": "^8.56.0",
|
|
25
|
-
"tsup": "^8.0.
|
|
26
|
-
"typescript": "^5.
|
|
27
|
-
"@pluv/tsconfig": "^0.
|
|
28
|
-
"@pluv/types": "^0.
|
|
29
|
-
"eslint-config-pluv": "^0.
|
|
26
|
+
"tsup": "^8.0.2",
|
|
27
|
+
"typescript": "^5.3.3",
|
|
28
|
+
"@pluv/tsconfig": "^0.16.0",
|
|
29
|
+
"@pluv/types": "^0.16.0",
|
|
30
|
+
"eslint-config-pluv": "^0.16.0"
|
|
30
31
|
},
|
|
31
32
|
"scripts": {
|
|
32
33
|
"build": "tsup src/index.ts --format esm,cjs --dts",
|
package/src/IndexedDBStorage.ts
CHANGED
package/src/addonIndexedDB.ts
CHANGED
|
@@ -1,11 +1,12 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { PluvRoom, PluvRoomAddon } from "@pluv/client";
|
|
2
|
+
import type { AbstractCrdtType } from "@pluv/crdt";
|
|
2
3
|
import type { IOLike, JsonObject } from "@pluv/types";
|
|
3
4
|
import { IndexedDBStorage } from "./IndexedDBStorage";
|
|
4
5
|
|
|
5
6
|
export interface AddonIndexedDBConfig<
|
|
6
7
|
TIO extends IOLike,
|
|
7
8
|
TPresence extends JsonObject = {},
|
|
8
|
-
TStorage extends Record<string,
|
|
9
|
+
TStorage extends Record<string, AbstractCrdtType<any, any>> = {},
|
|
9
10
|
> {
|
|
10
11
|
enabled?: boolean | ((room: PluvRoom<TIO, TPresence, TStorage>) => boolean);
|
|
11
12
|
}
|
|
@@ -13,7 +14,7 @@ export interface AddonIndexedDBConfig<
|
|
|
13
14
|
export const addonIndexedDB = <
|
|
14
15
|
TIO extends IOLike,
|
|
15
16
|
TPresence extends JsonObject = {},
|
|
16
|
-
TStorage extends Record<string,
|
|
17
|
+
TStorage extends Record<string, AbstractCrdtType<any, any>> = {},
|
|
17
18
|
>(
|
|
18
19
|
config?: AddonIndexedDBConfig<TIO, TPresence, TStorage>,
|
|
19
20
|
): PluvRoomAddon<TIO, TPresence, TStorage> => {
|