@pluv/react 2.2.1 → 2.2.3

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/dist/index.js CHANGED
@@ -80,8 +80,8 @@ var import_react6 = require("react");
80
80
  var import_react = require("react");
81
81
  var useAsyncQueue = () => {
82
82
  const queueRef = (0, import_react.useRef)(Promise.resolve(void 0));
83
- const push = (0, import_react.useCallback)((promise) => __async(void 0, null, function* () {
84
- queueRef.current = queueRef.current.then(() => __async(void 0, null, function* () {
83
+ const push = (0, import_react.useCallback)((promise) => __async(null, null, function* () {
84
+ queueRef.current = queueRef.current.then(() => __async(null, null, function* () {
85
85
  return yield promise;
86
86
  }));
87
87
  return yield queueRef.current;
@@ -255,7 +255,7 @@ var createBundle = (client, options = {}) => {
255
255
  const queue = useAsyncQueue();
256
256
  const rerender = useRerender();
257
257
  const mockedRoom = (0, import_react6.useContext)(MockedRoomContext);
258
- const resolvedMeta = useDeepAsyncMemo(() => __async(void 0, null, function* () {
258
+ const resolvedMeta = useDeepAsyncMemo(() => __async(null, null, function* () {
259
259
  const resolved = yield Promise.resolve(
260
260
  typeof metadata === "function" ? metadata() : metadata
261
261
  );
@@ -287,7 +287,7 @@ var createBundle = (client, options = {}) => {
287
287
  };
288
288
  }, [rerender, room]);
289
289
  (0, import_react6.useEffect)(() => {
290
- const leaveRoom = () => __async(void 0, null, function* () {
290
+ const leaveRoom = () => __async(null, null, function* () {
291
291
  yield queue.push(
292
292
  client.leave(room).catch((error) => {
293
293
  console.error(error);
@@ -304,7 +304,7 @@ var createBundle = (client, options = {}) => {
304
304
  }
305
305
  const resolved = resolvedMeta.value;
306
306
  queue.push(
307
- client.enter(room, ...[{ metadata: resolved }]).catch((error) => __async(void 0, null, function* () {
307
+ client.enter(room, ...[{ metadata: resolved }]).catch((error) => __async(null, null, function* () {
308
308
  console.error(error);
309
309
  yield leaveRoom();
310
310
  }))
package/dist/index.mjs CHANGED
@@ -56,8 +56,8 @@ import {
56
56
  import { useCallback, useMemo, useRef } from "react";
57
57
  var useAsyncQueue = () => {
58
58
  const queueRef = useRef(Promise.resolve(void 0));
59
- const push = useCallback((promise) => __async(void 0, null, function* () {
60
- queueRef.current = queueRef.current.then(() => __async(void 0, null, function* () {
59
+ const push = useCallback((promise) => __async(null, null, function* () {
60
+ queueRef.current = queueRef.current.then(() => __async(null, null, function* () {
61
61
  return yield promise;
62
62
  }));
63
63
  return yield queueRef.current;
@@ -231,7 +231,7 @@ var createBundle = (client, options = {}) => {
231
231
  const queue = useAsyncQueue();
232
232
  const rerender = useRerender();
233
233
  const mockedRoom = useContext(MockedRoomContext);
234
- const resolvedMeta = useDeepAsyncMemo(() => __async(void 0, null, function* () {
234
+ const resolvedMeta = useDeepAsyncMemo(() => __async(null, null, function* () {
235
235
  const resolved = yield Promise.resolve(
236
236
  typeof metadata === "function" ? metadata() : metadata
237
237
  );
@@ -263,7 +263,7 @@ var createBundle = (client, options = {}) => {
263
263
  };
264
264
  }, [rerender, room]);
265
265
  useEffect3(() => {
266
- const leaveRoom = () => __async(void 0, null, function* () {
266
+ const leaveRoom = () => __async(null, null, function* () {
267
267
  yield queue.push(
268
268
  client.leave(room).catch((error) => {
269
269
  console.error(error);
@@ -280,7 +280,7 @@ var createBundle = (client, options = {}) => {
280
280
  }
281
281
  const resolved = resolvedMeta.value;
282
282
  queue.push(
283
- client.enter(room, ...[{ metadata: resolved }]).catch((error) => __async(void 0, null, function* () {
283
+ client.enter(room, ...[{ metadata: resolved }]).catch((error) => __async(null, null, function* () {
284
284
  console.error(error);
285
285
  yield leaveRoom();
286
286
  }))
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pluv/react",
3
- "version": "2.2.1",
3
+ "version": "2.2.3",
4
4
  "description": "@pluv/client React.js bindings",
5
5
  "author": "leedavidcs",
6
6
  "license": "MIT",
@@ -18,22 +18,22 @@
18
18
  },
19
19
  "dependencies": {
20
20
  "fast-deep-equal": "^3.1.3",
21
- "@pluv/client": "^2.2.1",
22
- "@pluv/crdt": "^2.2.1",
23
- "@pluv/types": "^2.2.1"
21
+ "@pluv/client": "^2.2.3",
22
+ "@pluv/crdt": "^2.2.3",
23
+ "@pluv/types": "^2.2.3"
24
24
  },
25
25
  "peerDependencies": {
26
26
  "@types/react": "^18.0.0 || ^19.0.0",
27
27
  "react": "^18.0.0 || ^19.0.0"
28
28
  },
29
29
  "devDependencies": {
30
- "@types/react": "^19.1.4",
31
- "eslint": "^9.26.0",
30
+ "@types/react": "^19.1.5",
31
+ "eslint": "^9.27.0",
32
32
  "react": "^19.1.0",
33
- "tsup": "^8.4.0",
33
+ "tsup": "^8.5.0",
34
34
  "typescript": "^5.8.3",
35
- "@pluv/tsconfig": "^2.2.1",
36
- "eslint-config-pluv": "^2.2.1"
35
+ "@pluv/tsconfig": "^2.2.3",
36
+ "eslint-config-pluv": "^2.2.3"
37
37
  },
38
38
  "scripts": {
39
39
  "build": "tsup src/index.ts --format esm,cjs --dts --external react",