@actuallab/rpc 12.3.60 → 12.3.70
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.cjs +9 -12
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +5 -0
- package/dist/index.d.ts +5 -0
- package/dist/index.js +9 -12
- package/dist/index.js.map +1 -1
- package/package.json +3 -3
package/dist/index.cjs
CHANGED
|
@@ -233,20 +233,10 @@ function deserializeMessage(raw) {
|
|
|
233
233
|
var textEncoder = new TextEncoder();
|
|
234
234
|
var textDecoder = new TextDecoder();
|
|
235
235
|
var INITIAL_ENCODER_BUFFER_SIZE = 32 * 1024;
|
|
236
|
-
var defaultBinaryEncoder = new import_msgpack2.Encoder(
|
|
237
|
-
void 0,
|
|
238
|
-
void 0,
|
|
239
|
-
void 0,
|
|
240
|
-
INITIAL_ENCODER_BUFFER_SIZE
|
|
241
|
-
);
|
|
236
|
+
var defaultBinaryEncoder = new import_msgpack2.Encoder({ initialBufferSize: INITIAL_ENCODER_BUFFER_SIZE, useBigInt64: true });
|
|
242
237
|
var defaultBinaryDecoder = new import_msgpack2.Decoder();
|
|
243
238
|
function createBinaryEncoder() {
|
|
244
|
-
return new import_msgpack2.Encoder(
|
|
245
|
-
void 0,
|
|
246
|
-
void 0,
|
|
247
|
-
void 0,
|
|
248
|
-
INITIAL_ENCODER_BUFFER_SIZE
|
|
249
|
-
);
|
|
239
|
+
return new import_msgpack2.Encoder({ initialBufferSize: INITIAL_ENCODER_BUFFER_SIZE, useBigInt64: true });
|
|
250
240
|
}
|
|
251
241
|
function varUintByteLen(value) {
|
|
252
242
|
if (value < 0) value = 0;
|
|
@@ -2456,6 +2446,13 @@ var RpcPeer = class {
|
|
|
2456
2446
|
);
|
|
2457
2447
|
this._sendWireData(wireData);
|
|
2458
2448
|
}
|
|
2449
|
+
/** Close the current WS connection without disposing the peer. The
|
|
2450
|
+
* `conn.closed` handler flips state to `Disconnected`; for
|
|
2451
|
+
* `RpcClientPeer` the run loop then iterates and reopens. The peer
|
|
2452
|
+
* stays in the hub and all client proxies bound to it remain valid. */
|
|
2453
|
+
disconnect() {
|
|
2454
|
+
this._connection?.close();
|
|
2455
|
+
}
|
|
2459
2456
|
close() {
|
|
2460
2457
|
infoLog?.log(`'${this.ref}': Stopping`);
|
|
2461
2458
|
this.remoteObjects.disconnectAll();
|