@orpc/client 1.8.0 → 1.8.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/README.md CHANGED
@@ -31,7 +31,7 @@
31
31
  - **📘 First-Class OpenAPI**: Built-in support that fully adheres to the OpenAPI standard.
32
32
  - **📝 Contract-First Development**: Optionally define your API contract before implementation.
33
33
  - **🔍 First-Class OpenTelemetry**: Seamlessly integrate with OpenTelemetry for observability.
34
- - **⚙️ Framework Integrations**: Seamlessly integrate with TanStack Query (React, Vue, Solid, Svelte, Angular), Pinia Colada, and more.
34
+ - **⚙️ Framework Integrations**: Seamlessly integrate with TanStack Query (React, Vue, Solid, Svelte, Angular), SWR, Pinia Colada, and more.
35
35
  - **🚀 Server Actions**: Fully compatible with React Server Actions on Next.js, TanStack Start, and other platforms.
36
36
  - **🔠 Standard Schema Support**: Works out of the box with Zod, Valibot, ArkType, and other schema validators.
37
37
  - **🗃️ Native Types**: Supports native types like Date, File, Blob, BigInt, URL, and more.
@@ -54,6 +54,7 @@ You can find the full documentation [here](https://orpc.unnoq.com).
54
54
  - [@orpc/nest](https://www.npmjs.com/package/@orpc/nest): Deeply integrate oRPC with [NestJS](https://nestjs.com/).
55
55
  - [@orpc/react](https://www.npmjs.com/package/@orpc/react): Utilities for integrating oRPC with React and React Server Actions.
56
56
  - [@orpc/tanstack-query](https://www.npmjs.com/package/@orpc/tanstack-query): [TanStack Query](https://tanstack.com/query/latest) integration.
57
+ - [@orpc/experimental-react-swr](https://www.npmjs.com/package/@orpc/experimental-react-swr): [SWR](https://swr.vercel.app/) integration.
57
58
  - [@orpc/vue-colada](https://www.npmjs.com/package/@orpc/vue-colada): Integration with [Pinia Colada](https://pinia-colada.esm.dev/).
58
59
  - [@orpc/hey-api](https://www.npmjs.com/package/@orpc/hey-api): [Hey API](https://heyapi.dev/) integration.
59
60
  - [@orpc/zod](https://www.npmjs.com/package/@orpc/zod): More schemas that [Zod](https://zod.dev/) doesn't support yet.
package/dist/index.mjs CHANGED
@@ -1,7 +1,7 @@
1
+ import { preventNativeAwait, isTypescriptObject } from '@orpc/shared';
2
+ export { AsyncIteratorClass, EventPublisher, asyncIteratorToStream as eventIteratorToStream, onError, onFinish, onStart, onSuccess, streamToAsyncIteratorClass as streamToEventIterator } from '@orpc/shared';
1
3
  import { i as isDefinedError } from './shared/client.txdq_i5V.mjs';
2
4
  export { C as COMMON_ORPC_ERROR_DEFS, O as ORPCError, d as createORPCErrorFromJson, a as fallbackORPCErrorMessage, f as fallbackORPCErrorStatus, c as isORPCErrorJson, b as isORPCErrorStatus, m as mapEventIterator, t as toORPCError } from './shared/client.txdq_i5V.mjs';
3
- import { isTypescriptObject } from '@orpc/shared';
4
- export { AsyncIteratorClass, EventPublisher, asyncIteratorToStream as eventIteratorToStream, onError, onFinish, onStart, onSuccess, streamToAsyncIteratorClass as streamToEventIterator } from '@orpc/shared';
5
5
  export { ErrorEvent } from '@orpc/standard-server';
6
6
 
7
7
  async function safe(promise) {
@@ -49,7 +49,7 @@ function createORPCClient(link, options = {}) {
49
49
  });
50
50
  }
51
51
  });
52
- return recursive;
52
+ return preventNativeAwait(recursive);
53
53
  }
54
54
 
55
55
  function createSafeClient(client) {
@@ -330,7 +330,7 @@ class ClientRetryPlugin {
330
330
  if (!isAsyncIteratorObject(output)) {
331
331
  return output;
332
332
  }
333
- return async function* () {
333
+ return (async function* () {
334
334
  let current = output;
335
335
  try {
336
336
  while (true) {
@@ -359,7 +359,7 @@ class ClientRetryPlugin {
359
359
  } finally {
360
360
  await current.return?.();
361
361
  }
362
- }();
362
+ })();
363
363
  });
364
364
  }
365
365
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@orpc/client",
3
3
  "type": "module",
4
- "version": "1.8.0",
4
+ "version": "1.8.2",
5
5
  "license": "MIT",
6
6
  "homepage": "https://orpc.unnoq.com",
7
7
  "repository": {
@@ -49,13 +49,13 @@
49
49
  "dist"
50
50
  ],
51
51
  "dependencies": {
52
- "@orpc/shared": "1.8.0",
53
- "@orpc/standard-server": "1.8.0",
54
- "@orpc/standard-server-fetch": "1.8.0",
55
- "@orpc/standard-server-peer": "1.8.0"
52
+ "@orpc/shared": "1.8.2",
53
+ "@orpc/standard-server-fetch": "1.8.2",
54
+ "@orpc/standard-server": "1.8.2",
55
+ "@orpc/standard-server-peer": "1.8.2"
56
56
  },
57
57
  "devDependencies": {
58
- "zod": "^4.0.14"
58
+ "zod": "^4.0.17"
59
59
  },
60
60
  "scripts": {
61
61
  "build": "unbuild",