@yorkie-js/react 0.7.10-rc → 0.7.10-rc2

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.
@@ -20975,7 +20975,7 @@
20975
20975
  };
20976
20976
  }
20977
20977
  const name$1 = "@yorkie-js/sdk";
20978
- const version$1 = "0.7.10-rc";
20978
+ const version$1 = "0.7.10-rc2";
20979
20979
  const pkg$1 = {
20980
20980
  name: name$1,
20981
20981
  version: version$1
@@ -21335,10 +21335,43 @@
21335
21335
  baseUrl: rpcAddr,
21336
21336
  interceptors: [authInterceptor, createMetricInterceptor(opts?.userAgent)],
21337
21337
  fetch: (input, init) => {
21338
+ const url = typeof input === "string" ? input : input instanceof URL ? input.toString() : input.url;
21339
+ if (/\/yorkie\.v1\.YorkieService\/Watch/.test(url)) {
21340
+ return fetch(input, {
21341
+ ...init,
21342
+ keepalive: this.keepalive
21343
+ });
21344
+ }
21345
+ const callerSignal = init?.signal ?? (input instanceof Request ? input.signal : void 0);
21346
+ const innerAC = new AbortController();
21347
+ let onCallerAbort;
21348
+ if (callerSignal) {
21349
+ if (callerSignal.aborted) {
21350
+ innerAC.abort(callerSignal.reason);
21351
+ } else {
21352
+ onCallerAbort = () => innerAC.abort(callerSignal.reason);
21353
+ callerSignal.addEventListener("abort", onCallerAbort);
21354
+ }
21355
+ }
21356
+ const detach = () => {
21357
+ if (callerSignal && onCallerAbort) {
21358
+ callerSignal.removeEventListener("abort", onCallerAbort);
21359
+ }
21360
+ };
21338
21361
  return fetch(input, {
21339
21362
  ...init,
21363
+ signal: innerAC.signal,
21340
21364
  keepalive: this.keepalive
21341
- });
21365
+ }).then(
21366
+ (res) => {
21367
+ detach();
21368
+ return res;
21369
+ },
21370
+ (err) => {
21371
+ detach();
21372
+ throw err;
21373
+ }
21374
+ );
21342
21375
  }
21343
21376
  };
21344
21377
  this.rpcClient = createClient(
@@ -23023,7 +23056,7 @@
23023
23056
  };
23024
23057
  }
23025
23058
  const name = "@yorkie-js/react";
23026
- const version = "0.7.10-rc";
23059
+ const version = "0.7.10-rc2";
23027
23060
  const pkg = {
23028
23061
  name,
23029
23062
  version