@pluv/io 0.4.1 → 0.4.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/.turbo/turbo-build.log +7 -7
- package/CHANGELOG.md +6 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.js +3 -0
- package/dist/index.mjs +3 -0
- package/package.json +1 -1
- package/src/PluvIO.ts +5 -1
package/.turbo/turbo-build.log
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
> @pluv/io@0.4.
|
|
2
|
+
> @pluv/io@0.4.2 build /home/runner/work/pluv/pluv/packages/io
|
|
3
3
|
> tsup src/index.ts --format esm,cjs --dts
|
|
4
4
|
|
|
5
5
|
[34mCLI[39m Building entry: src/index.ts
|
|
@@ -8,10 +8,10 @@
|
|
|
8
8
|
[34mCLI[39m Target: es6
|
|
9
9
|
[34mESM[39m Build start
|
|
10
10
|
[34mCJS[39m Build start
|
|
11
|
-
[32mCJS[39m [1mdist/index.js [22m[32m30.
|
|
12
|
-
[32mCJS[39m ⚡️ Build success in
|
|
13
|
-
[32mESM[39m [1mdist/index.mjs [22m[
|
|
14
|
-
[32mESM[39m ⚡️ Build success in
|
|
11
|
+
[32mCJS[39m [1mdist/index.js [22m[32m30.12 KB[39m
|
|
12
|
+
[32mCJS[39m ⚡️ Build success in 109ms
|
|
13
|
+
[32mESM[39m [1mdist/index.mjs [22m[32m28.06 KB[39m
|
|
14
|
+
[32mESM[39m ⚡️ Build success in 112ms
|
|
15
15
|
[34mDTS[39m Build start
|
|
16
|
-
[32mDTS[39m ⚡️ Build success in
|
|
17
|
-
[32mDTS[39m [1mdist/index.d.ts [22m[32m14.
|
|
16
|
+
[32mDTS[39m ⚡️ Build success in 3144ms
|
|
17
|
+
[32mDTS[39m [1mdist/index.d.ts [22m[32m14.86 KB[39m
|
package/CHANGELOG.md
CHANGED
package/dist/index.d.ts
CHANGED
|
@@ -247,11 +247,11 @@ interface GetRoomOptions {
|
|
|
247
247
|
declare class PluvIO<TPlatform extends AbstractPlatform<any> = AbstractPlatform<any>, TAuthorize extends IOAuthorize<any, any> = BaseIOAuthorize, TContext extends JsonObject = {}, TInput extends EventRecord<string, any> = {}, TOutputBroadcast extends EventRecord<string, any> = {}, TOutputSelf extends EventRecord<string, any> = {}, TOutputSync extends EventRecord<string, any> = {}> implements IOLike<TAuthorize, TInput, TOutputBroadcast, TOutputSelf, TOutputSync> {
|
|
248
248
|
private _context;
|
|
249
249
|
private _initialStorage;
|
|
250
|
-
private _listeners;
|
|
251
250
|
private _rooms;
|
|
252
251
|
readonly _authorize: TAuthorize | null;
|
|
253
252
|
readonly _debug: boolean;
|
|
254
253
|
readonly _events: InferEventConfig<TContext, TInput, TOutputBroadcast, TOutputSelf, TOutputSync>;
|
|
254
|
+
readonly _listeners: PluvIOListeners;
|
|
255
255
|
readonly _platform: TPlatform;
|
|
256
256
|
constructor(options: PluvIOConfig<TPlatform, TAuthorize, TContext, TInput, TOutputBroadcast, TOutputSelf, TOutputSync>);
|
|
257
257
|
createToken(params: JWTEncodeParams<InferIOAuthorizeUser<InferIOAuthorize<this>>>): Promise<string>;
|
package/dist/index.js
CHANGED
|
@@ -924,11 +924,14 @@ var PluvIO = class {
|
|
|
924
924
|
const platform = first._platform;
|
|
925
925
|
const events1 = first._events;
|
|
926
926
|
const events2 = second._events;
|
|
927
|
+
const { onRoomDeleted, onStorageUpdated } = first._listeners;
|
|
927
928
|
const events = Object.assign(/* @__PURE__ */ Object.create(null), events1, events2);
|
|
928
929
|
return new PluvIO({
|
|
929
930
|
authorize: authorize2,
|
|
930
931
|
debug,
|
|
931
932
|
events,
|
|
933
|
+
onRoomDeleted,
|
|
934
|
+
onStorageUpdated,
|
|
932
935
|
platform
|
|
933
936
|
});
|
|
934
937
|
}
|
package/dist/index.mjs
CHANGED
|
@@ -887,11 +887,14 @@ var PluvIO = class {
|
|
|
887
887
|
const platform = first._platform;
|
|
888
888
|
const events1 = first._events;
|
|
889
889
|
const events2 = second._events;
|
|
890
|
+
const { onRoomDeleted, onStorageUpdated } = first._listeners;
|
|
890
891
|
const events = Object.assign(/* @__PURE__ */ Object.create(null), events1, events2);
|
|
891
892
|
return new PluvIO({
|
|
892
893
|
authorize: authorize2,
|
|
893
894
|
debug,
|
|
894
895
|
events,
|
|
896
|
+
onRoomDeleted,
|
|
897
|
+
onStorageUpdated,
|
|
895
898
|
platform
|
|
896
899
|
});
|
|
897
900
|
}
|
package/package.json
CHANGED
package/src/PluvIO.ts
CHANGED
|
@@ -105,7 +105,6 @@ export class PluvIO<
|
|
|
105
105
|
private _initialStorage:
|
|
106
106
|
| ((room: string) => MaybePromise<Maybe<string>>)
|
|
107
107
|
| null = null;
|
|
108
|
-
private _listeners: PluvIOListeners;
|
|
109
108
|
private _rooms = new Map<
|
|
110
109
|
string,
|
|
111
110
|
IORoom<
|
|
@@ -256,6 +255,7 @@ export class PluvIO<
|
|
|
256
255
|
TOutputSelf,
|
|
257
256
|
TOutputSync
|
|
258
257
|
>;
|
|
258
|
+
readonly _listeners: PluvIOListeners;
|
|
259
259
|
readonly _platform: TPlatform;
|
|
260
260
|
|
|
261
261
|
constructor(
|
|
@@ -467,12 +467,16 @@ export class PluvIO<
|
|
|
467
467
|
const events1 = first._events;
|
|
468
468
|
const events2 = second._events;
|
|
469
469
|
|
|
470
|
+
const { onRoomDeleted, onStorageUpdated } = first._listeners;
|
|
471
|
+
|
|
470
472
|
const events = Object.assign(Object.create(null), events1, events2);
|
|
471
473
|
|
|
472
474
|
return new PluvIO({
|
|
473
475
|
authorize,
|
|
474
476
|
debug,
|
|
475
477
|
events,
|
|
478
|
+
onRoomDeleted,
|
|
479
|
+
onStorageUpdated,
|
|
476
480
|
platform,
|
|
477
481
|
});
|
|
478
482
|
}
|