@orderly.network/hooks 3.0.0-beta.0 → 3.0.0-beta.1

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.d.mts CHANGED
@@ -37,7 +37,7 @@ declare global {
37
37
  };
38
38
  }
39
39
  }
40
- declare const _default: "3.0.0-beta.0";
40
+ declare const _default: "3.0.0-beta.1";
41
41
 
42
42
  declare const fetcher: (url: string, init: RequestInit | undefined, queryOptions: useQueryOptions<any>) => Promise<any>;
43
43
  type useQueryOptions<T> = SWRConfiguration & {
package/dist/index.d.ts CHANGED
@@ -37,7 +37,7 @@ declare global {
37
37
  };
38
38
  }
39
39
  }
40
- declare const _default: "3.0.0-beta.0";
40
+ declare const _default: "3.0.0-beta.1";
41
41
 
42
42
  declare const fetcher: (url: string, init: RequestInit | undefined, queryOptions: useQueryOptions<any>) => Promise<any>;
43
43
  type useQueryOptions<T> = SWRConfiguration & {
package/dist/index.js CHANGED
@@ -3,8 +3,8 @@
3
3
  var net = require('@orderly.network/net');
4
4
  var React = require('react');
5
5
  var useSWR5 = require('swr');
6
- var types = require('@orderly.network/types');
7
6
  var pluginCore = require('@orderly.network/plugin-core');
7
+ var types = require('@orderly.network/types');
8
8
  var utils = require('@orderly.network/utils');
9
9
  var useSWRMutation = require('swr/mutation');
10
10
  var useConstant = require('use-constant');
@@ -65,9 +65,9 @@ var __export = (target, all) => {
65
65
  // src/version.ts
66
66
  if (typeof window !== "undefined") {
67
67
  window.__ORDERLY_VERSION__ = window.__ORDERLY_VERSION__ || {};
68
- window.__ORDERLY_VERSION__["@orderly.network/hooks"] = "3.0.0-beta.0";
68
+ window.__ORDERLY_VERSION__["@orderly.network/hooks"] = "3.0.0-beta.1";
69
69
  }
70
- var version_default = "3.0.0-beta.0";
70
+ var version_default = "3.0.0-beta.1";
71
71
  var fetcher = (url, init2 = {}, queryOptions) => net.get(url, init2, queryOptions?.formatter);
72
72
  var noCacheConfig = {
73
73
  dedupingInterval: 0,
@@ -98,6 +98,8 @@ function useConfig(key, defaultValue) {
98
98
  }
99
99
  return configStore;
100
100
  }
101
+
102
+ // src/useQuery.ts
101
103
  var PLUGIN_ID_HEADER = "X-Orderly-Plugin-Id";
102
104
  var useQuery = (query, options) => {
103
105
  const apiBaseUrl = useConfig("apiBaseUrl");