@metamask-previews/react-data-query 1.0.0-preview-8bfa290fb → 2.0.0-preview-0a30e47
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/CHANGELOG.md +9 -8
- package/dist/{createUIQueryClient.d.mts → createUIQueryClient.d.ts} +3 -3
- package/dist/createUIQueryClient.d.ts.map +1 -0
- package/dist/createUIQueryClient.js +128 -0
- package/dist/createUIQueryClient.js.map +1 -0
- package/dist/{hooks.d.mts → hooks.d.ts} +3 -18
- package/dist/hooks.d.ts.map +1 -0
- package/dist/{hooks.mjs → hooks.js} +4 -21
- package/dist/hooks.js.map +1 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +3 -0
- package/dist/index.js.map +1 -0
- package/package.json +15 -21
- package/dist/createUIQueryClient.cjs +0 -219
- package/dist/createUIQueryClient.cjs.map +0 -1
- package/dist/createUIQueryClient.d.cts +0 -51
- package/dist/createUIQueryClient.d.cts.map +0 -1
- package/dist/createUIQueryClient.d.mts.map +0 -1
- package/dist/createUIQueryClient.mjs +0 -215
- package/dist/createUIQueryClient.mjs.map +0 -1
- package/dist/hooks.cjs +0 -56
- package/dist/hooks.cjs.map +0 -1
- package/dist/hooks.d.cts +0 -36
- package/dist/hooks.d.cts.map +0 -1
- package/dist/hooks.d.mts.map +0 -1
- package/dist/hooks.mjs.map +0 -1
- package/dist/hydrateMutations.cjs +0 -100
- package/dist/hydrateMutations.cjs.map +0 -1
- package/dist/hydrateMutations.d.cts +0 -35
- package/dist/hydrateMutations.d.cts.map +0 -1
- package/dist/hydrateMutations.d.mts +0 -35
- package/dist/hydrateMutations.d.mts.map +0 -1
- package/dist/hydrateMutations.mjs +0 -95
- package/dist/hydrateMutations.mjs.map +0 -1
- package/dist/index.cjs +0 -10
- package/dist/index.cjs.map +0 -1
- package/dist/index.d.cts +0 -3
- package/dist/index.d.cts.map +0 -1
- package/dist/index.d.mts +0 -3
- package/dist/index.d.mts.map +0 -1
- package/dist/index.mjs +0 -3
- package/dist/index.mjs.map +0 -1
- package/dist/loggers.cjs +0 -7
- package/dist/loggers.cjs.map +0 -1
- package/dist/loggers.d.cts +0 -5
- package/dist/loggers.d.cts.map +0 -1
- package/dist/loggers.d.mts +0 -5
- package/dist/loggers.d.mts.map +0 -1
- package/dist/loggers.mjs +0 -4
- package/dist/loggers.mjs.map +0 -1
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
import { QueryClient, DehydratedState } from "@tanstack/query-core";
|
|
2
|
-
/**
|
|
3
|
-
* Get the `globalId` of a mutation by reading its `meta` data.
|
|
4
|
-
*
|
|
5
|
-
* Each mutation that is routed from the UI query client to a data service is
|
|
6
|
-
* assigned a `globalId` through the mutation's `meta` property. However, the
|
|
7
|
-
* `meta` property is optional and untyped, so reading this property back
|
|
8
|
-
* requires some validation.
|
|
9
|
-
*
|
|
10
|
-
* @param meta - The mutation `meta`, if any.
|
|
11
|
-
* @returns The `globalId` if present and a string, otherwise undefined.
|
|
12
|
-
*/
|
|
13
|
-
export declare function readGlobalId(meta: Record<string, unknown> | undefined): string | undefined;
|
|
14
|
-
/**
|
|
15
|
-
* Load dehydrated mutations into the given query client.
|
|
16
|
-
*
|
|
17
|
-
* TanStack Query's `hydrate` function works well for queries: it ensures that
|
|
18
|
-
* incoming queries remain deduplicated as it hydrates them (using the query key
|
|
19
|
-
* hash as a filter). But mutations don't need to be deduplicated, and so
|
|
20
|
-
* `hydrate` follows a different process, opting to load incoming mutations as
|
|
21
|
-
* new entries each time it is called.
|
|
22
|
-
*
|
|
23
|
-
* This does not well for what we want to achieve, which is to be able to
|
|
24
|
-
* synchronize queries and mutations between a data service query client service
|
|
25
|
-
* and a UI query client. To accomplish this, we assume that mutations which
|
|
26
|
-
* originated on the UI side have been tagged with a custom UUID (stored as
|
|
27
|
-
* `globalId` in its `meta`). This allows us to keep mutations with the same
|
|
28
|
-
* UUID on both sides and thus sychronize them effectively.
|
|
29
|
-
*
|
|
30
|
-
* @param client - The UI query client whose mutation cache should be hydrated.
|
|
31
|
-
* @param dehydratedState - The dehydrated state emitted by a data service's
|
|
32
|
-
* `:cacheUpdated` event.
|
|
33
|
-
*/
|
|
34
|
-
export declare function hydrateMutations(client: QueryClient, dehydratedState: DehydratedState): void;
|
|
35
|
-
//# sourceMappingURL=hydrateMutations.d.cts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"hydrateMutations.d.cts","sourceRoot":"","sources":["../src/hydrateMutations.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,WAAW,EACX,eAAe,EAEhB,6BAA6B;AAE9B;;;;;;;;;;GAUG;AACH,wBAAgB,YAAY,CAC1B,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,SAAS,GACxC,MAAM,GAAG,SAAS,CAGpB;AAED;;;;;;;;;;;;;;;;;;;GAmBG;AACH,wBAAgB,gBAAgB,CAC9B,MAAM,EAAE,WAAW,EACnB,eAAe,EAAE,eAAe,GAC/B,IAAI,CAkCN"}
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
import { QueryClient, DehydratedState } from "@tanstack/query-core";
|
|
2
|
-
/**
|
|
3
|
-
* Get the `globalId` of a mutation by reading its `meta` data.
|
|
4
|
-
*
|
|
5
|
-
* Each mutation that is routed from the UI query client to a data service is
|
|
6
|
-
* assigned a `globalId` through the mutation's `meta` property. However, the
|
|
7
|
-
* `meta` property is optional and untyped, so reading this property back
|
|
8
|
-
* requires some validation.
|
|
9
|
-
*
|
|
10
|
-
* @param meta - The mutation `meta`, if any.
|
|
11
|
-
* @returns The `globalId` if present and a string, otherwise undefined.
|
|
12
|
-
*/
|
|
13
|
-
export declare function readGlobalId(meta: Record<string, unknown> | undefined): string | undefined;
|
|
14
|
-
/**
|
|
15
|
-
* Load dehydrated mutations into the given query client.
|
|
16
|
-
*
|
|
17
|
-
* TanStack Query's `hydrate` function works well for queries: it ensures that
|
|
18
|
-
* incoming queries remain deduplicated as it hydrates them (using the query key
|
|
19
|
-
* hash as a filter). But mutations don't need to be deduplicated, and so
|
|
20
|
-
* `hydrate` follows a different process, opting to load incoming mutations as
|
|
21
|
-
* new entries each time it is called.
|
|
22
|
-
*
|
|
23
|
-
* This does not well for what we want to achieve, which is to be able to
|
|
24
|
-
* synchronize queries and mutations between a data service query client service
|
|
25
|
-
* and a UI query client. To accomplish this, we assume that mutations which
|
|
26
|
-
* originated on the UI side have been tagged with a custom UUID (stored as
|
|
27
|
-
* `globalId` in its `meta`). This allows us to keep mutations with the same
|
|
28
|
-
* UUID on both sides and thus sychronize them effectively.
|
|
29
|
-
*
|
|
30
|
-
* @param client - The UI query client whose mutation cache should be hydrated.
|
|
31
|
-
* @param dehydratedState - The dehydrated state emitted by a data service's
|
|
32
|
-
* `:cacheUpdated` event.
|
|
33
|
-
*/
|
|
34
|
-
export declare function hydrateMutations(client: QueryClient, dehydratedState: DehydratedState): void;
|
|
35
|
-
//# sourceMappingURL=hydrateMutations.d.mts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"hydrateMutations.d.mts","sourceRoot":"","sources":["../src/hydrateMutations.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,WAAW,EACX,eAAe,EAEhB,6BAA6B;AAE9B;;;;;;;;;;GAUG;AACH,wBAAgB,YAAY,CAC1B,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,SAAS,GACxC,MAAM,GAAG,SAAS,CAGpB;AAED;;;;;;;;;;;;;;;;;;;GAmBG;AACH,wBAAgB,gBAAgB,CAC9B,MAAM,EAAE,WAAW,EACnB,eAAe,EAAE,eAAe,GAC/B,IAAI,CAkCN"}
|
|
@@ -1,95 +0,0 @@
|
|
|
1
|
-
import { QueryClient } from "@tanstack/query-core";
|
|
2
|
-
/**
|
|
3
|
-
* Get the `globalId` of a mutation by reading its `meta` data.
|
|
4
|
-
*
|
|
5
|
-
* Each mutation that is routed from the UI query client to a data service is
|
|
6
|
-
* assigned a `globalId` through the mutation's `meta` property. However, the
|
|
7
|
-
* `meta` property is optional and untyped, so reading this property back
|
|
8
|
-
* requires some validation.
|
|
9
|
-
*
|
|
10
|
-
* @param meta - The mutation `meta`, if any.
|
|
11
|
-
* @returns The `globalId` if present and a string, otherwise undefined.
|
|
12
|
-
*/
|
|
13
|
-
export function readGlobalId(meta) {
|
|
14
|
-
const globalId = meta?.globalId;
|
|
15
|
-
return typeof globalId === 'string' ? globalId : undefined;
|
|
16
|
-
}
|
|
17
|
-
/**
|
|
18
|
-
* Load dehydrated mutations into the given query client.
|
|
19
|
-
*
|
|
20
|
-
* TanStack Query's `hydrate` function works well for queries: it ensures that
|
|
21
|
-
* incoming queries remain deduplicated as it hydrates them (using the query key
|
|
22
|
-
* hash as a filter). But mutations don't need to be deduplicated, and so
|
|
23
|
-
* `hydrate` follows a different process, opting to load incoming mutations as
|
|
24
|
-
* new entries each time it is called.
|
|
25
|
-
*
|
|
26
|
-
* This does not well for what we want to achieve, which is to be able to
|
|
27
|
-
* synchronize queries and mutations between a data service query client service
|
|
28
|
-
* and a UI query client. To accomplish this, we assume that mutations which
|
|
29
|
-
* originated on the UI side have been tagged with a custom UUID (stored as
|
|
30
|
-
* `globalId` in its `meta`). This allows us to keep mutations with the same
|
|
31
|
-
* UUID on both sides and thus sychronize them effectively.
|
|
32
|
-
*
|
|
33
|
-
* @param client - The UI query client whose mutation cache should be hydrated.
|
|
34
|
-
* @param dehydratedState - The dehydrated state emitted by a data service's
|
|
35
|
-
* `:cacheUpdated` event.
|
|
36
|
-
*/
|
|
37
|
-
export function hydrateMutations(client, dehydratedState) {
|
|
38
|
-
const mutationCache = client.getMutationCache();
|
|
39
|
-
for (const dehydratedMutation of dehydratedState.mutations) {
|
|
40
|
-
const { mutationKey, state, meta } = dehydratedMutation;
|
|
41
|
-
const globalId = readGlobalId(meta);
|
|
42
|
-
// Although TanStack Query does not require mutations to have mutation keys,
|
|
43
|
-
// all mutations created through data services or the UI query client *must*
|
|
44
|
-
// have one. They must also have a global ID.
|
|
45
|
-
if (!mutationKey || !globalId) {
|
|
46
|
-
continue;
|
|
47
|
-
}
|
|
48
|
-
const existingMutation = mutationCache.find({
|
|
49
|
-
mutationKey,
|
|
50
|
-
predicate: (mutation) => readGlobalId(mutation.meta) === globalId,
|
|
51
|
-
});
|
|
52
|
-
// A UI query client only subscribes to a mutation key's cache updates after
|
|
53
|
-
// it has built a mutation for that key, so there is always a matching
|
|
54
|
-
// mutation to update in place, and we can disregard the case in which there
|
|
55
|
-
// is not.
|
|
56
|
-
// istanbul ignore else
|
|
57
|
-
if (existingMutation) {
|
|
58
|
-
existingMutation.state = state;
|
|
59
|
-
mutationCache.notify({
|
|
60
|
-
type: 'updated',
|
|
61
|
-
mutation: existingMutation,
|
|
62
|
-
action: deriveMutationAction(state),
|
|
63
|
-
});
|
|
64
|
-
}
|
|
65
|
-
}
|
|
66
|
-
}
|
|
67
|
-
/**
|
|
68
|
-
* When publishing an `update` event through the mutation cache we must supply
|
|
69
|
-
* an action. This function derives an appropriate action from a dehydrated
|
|
70
|
-
* mutation's state.
|
|
71
|
-
*
|
|
72
|
-
* @param state - The state of a dehydrated mutation.
|
|
73
|
-
* @returns The mutation cache action describing the state.
|
|
74
|
-
*/
|
|
75
|
-
function deriveMutationAction(state) {
|
|
76
|
-
switch (state.status) {
|
|
77
|
-
case 'success':
|
|
78
|
-
return { type: 'success', data: state.data };
|
|
79
|
-
case 'error':
|
|
80
|
-
// A mutation in the `error` state always carries a non-null `error`.
|
|
81
|
-
return { type: 'error', error: state.error };
|
|
82
|
-
case 'pending':
|
|
83
|
-
return {
|
|
84
|
-
type: 'pending',
|
|
85
|
-
variables: state.variables,
|
|
86
|
-
context: state.context,
|
|
87
|
-
isPaused: state.isPaused,
|
|
88
|
-
};
|
|
89
|
-
// The `idle` status carries no data, error, or variables, so a neutral
|
|
90
|
-
// `continue` action refreshes subscribers without implying a result.
|
|
91
|
-
default:
|
|
92
|
-
return { type: 'continue' };
|
|
93
|
-
}
|
|
94
|
-
}
|
|
95
|
-
//# sourceMappingURL=hydrateMutations.mjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"hydrateMutations.mjs","sourceRoot":"","sources":["../src/hydrateMutations.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,WAAW,EAGZ,6BAA6B;AAE9B;;;;;;;;;;GAUG;AACH,MAAM,UAAU,YAAY,CAC1B,IAAyC;IAEzC,MAAM,QAAQ,GAAG,IAAI,EAAE,QAAQ,CAAC;IAChC,OAAO,OAAO,QAAQ,KAAK,QAAQ,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,SAAS,CAAC;AAC7D,CAAC;AAED;;;;;;;;;;;;;;;;;;;GAmBG;AACH,MAAM,UAAU,gBAAgB,CAC9B,MAAmB,EACnB,eAAgC;IAEhC,MAAM,aAAa,GAAG,MAAM,CAAC,gBAAgB,EAAE,CAAC;IAEhD,KAAK,MAAM,kBAAkB,IAAI,eAAe,CAAC,SAAS,EAAE,CAAC;QAC3D,MAAM,EAAE,WAAW,EAAE,KAAK,EAAE,IAAI,EAAE,GAAG,kBAAkB,CAAC;QAExD,MAAM,QAAQ,GAAG,YAAY,CAAC,IAAI,CAAC,CAAC;QAEpC,4EAA4E;QAC5E,4EAA4E;QAC5E,6CAA6C;QAC7C,IAAI,CAAC,WAAW,IAAI,CAAC,QAAQ,EAAE,CAAC;YAC9B,SAAS;QACX,CAAC;QAED,MAAM,gBAAgB,GAAG,aAAa,CAAC,IAAI,CAAC;YAC1C,WAAW;YACX,SAAS,EAAE,CAAC,QAAQ,EAAE,EAAE,CAAC,YAAY,CAAC,QAAQ,CAAC,IAAI,CAAC,KAAK,QAAQ;SAClE,CAAC,CAAC;QAEH,4EAA4E;QAC5E,sEAAsE;QACtE,4EAA4E;QAC5E,UAAU;QACV,uBAAuB;QACvB,IAAI,gBAAgB,EAAE,CAAC;YACrB,gBAAgB,CAAC,KAAK,GAAG,KAAK,CAAC;YAC/B,aAAa,CAAC,MAAM,CAAC;gBACnB,IAAI,EAAE,SAAS;gBACf,QAAQ,EAAE,gBAAgB;gBAC1B,MAAM,EAAE,oBAAoB,CAAC,KAAK,CAAC;aACpC,CAAC,CAAC;QACL,CAAC;IACH,CAAC;AACH,CAAC;AAED;;;;;;;GAOG;AACH,SAAS,oBAAoB,CAC3B,KAAoB;IAMpB,QAAQ,KAAK,CAAC,MAAM,EAAE,CAAC;QACrB,KAAK,SAAS;YACZ,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,IAAI,EAAE,KAAK,CAAC,IAAI,EAAE,CAAC;QAC/C,KAAK,OAAO;YACV,qEAAqE;YACrE,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,KAAK,EAAE,KAAK,CAAC,KAAK,EAAE,CAAC;QAC/C,KAAK,SAAS;YACZ,OAAO;gBACL,IAAI,EAAE,SAAS;gBACf,SAAS,EAAE,KAAK,CAAC,SAAS;gBAC1B,OAAO,EAAE,KAAK,CAAC,OAAO;gBACtB,QAAQ,EAAE,KAAK,CAAC,QAAQ;aACzB,CAAC;QACJ,uEAAuE;QACvE,qEAAqE;QACrE;YACE,OAAO,EAAE,IAAI,EAAE,UAAU,EAAE,CAAC;IAChC,CAAC;AACH,CAAC","sourcesContent":["import {\n QueryClient,\n DehydratedState,\n MutationState,\n} from '@tanstack/query-core';\n\n/**\n * Get the `globalId` of a mutation by reading its `meta` data.\n *\n * Each mutation that is routed from the UI query client to a data service is\n * assigned a `globalId` through the mutation's `meta` property. However, the\n * `meta` property is optional and untyped, so reading this property back\n * requires some validation.\n *\n * @param meta - The mutation `meta`, if any.\n * @returns The `globalId` if present and a string, otherwise undefined.\n */\nexport function readGlobalId(\n meta: Record<string, unknown> | undefined,\n): string | undefined {\n const globalId = meta?.globalId;\n return typeof globalId === 'string' ? globalId : undefined;\n}\n\n/**\n * Load dehydrated mutations into the given query client.\n *\n * TanStack Query's `hydrate` function works well for queries: it ensures that\n * incoming queries remain deduplicated as it hydrates them (using the query key\n * hash as a filter). But mutations don't need to be deduplicated, and so\n * `hydrate` follows a different process, opting to load incoming mutations as\n * new entries each time it is called.\n *\n * This does not well for what we want to achieve, which is to be able to\n * synchronize queries and mutations between a data service query client service\n * and a UI query client. To accomplish this, we assume that mutations which\n * originated on the UI side have been tagged with a custom UUID (stored as\n * `globalId` in its `meta`). This allows us to keep mutations with the same\n * UUID on both sides and thus sychronize them effectively.\n *\n * @param client - The UI query client whose mutation cache should be hydrated.\n * @param dehydratedState - The dehydrated state emitted by a data service's\n * `:cacheUpdated` event.\n */\nexport function hydrateMutations(\n client: QueryClient,\n dehydratedState: DehydratedState,\n): void {\n const mutationCache = client.getMutationCache();\n\n for (const dehydratedMutation of dehydratedState.mutations) {\n const { mutationKey, state, meta } = dehydratedMutation;\n\n const globalId = readGlobalId(meta);\n\n // Although TanStack Query does not require mutations to have mutation keys,\n // all mutations created through data services or the UI query client *must*\n // have one. They must also have a global ID.\n if (!mutationKey || !globalId) {\n continue;\n }\n\n const existingMutation = mutationCache.find({\n mutationKey,\n predicate: (mutation) => readGlobalId(mutation.meta) === globalId,\n });\n\n // A UI query client only subscribes to a mutation key's cache updates after\n // it has built a mutation for that key, so there is always a matching\n // mutation to update in place, and we can disregard the case in which there\n // is not.\n // istanbul ignore else\n if (existingMutation) {\n existingMutation.state = state;\n mutationCache.notify({\n type: 'updated',\n mutation: existingMutation,\n action: deriveMutationAction(state),\n });\n }\n }\n}\n\n/**\n * When publishing an `update` event through the mutation cache we must supply\n * an action. This function derives an appropriate action from a dehydrated\n * mutation's state.\n *\n * @param state - The state of a dehydrated mutation.\n * @returns The mutation cache action describing the state.\n */\nfunction deriveMutationAction(\n state: MutationState,\n):\n | { type: 'success'; data: unknown }\n | { type: 'error'; error: unknown }\n | { type: 'pending'; variables: unknown; context: unknown; isPaused: boolean }\n | { type: 'continue' } {\n switch (state.status) {\n case 'success':\n return { type: 'success', data: state.data };\n case 'error':\n // A mutation in the `error` state always carries a non-null `error`.\n return { type: 'error', error: state.error };\n case 'pending':\n return {\n type: 'pending',\n variables: state.variables,\n context: state.context,\n isPaused: state.isPaused,\n };\n // The `idle` status carries no data, error, or variables, so a neutral\n // `continue` action refreshes subscribers without implying a result.\n default:\n return { type: 'continue' };\n }\n}\n"]}
|
package/dist/index.cjs
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.useMutation = exports.useInfiniteQuery = exports.useQuery = exports.createUIQueryClient = void 0;
|
|
4
|
-
var createUIQueryClient_js_1 = require("./createUIQueryClient.cjs");
|
|
5
|
-
Object.defineProperty(exports, "createUIQueryClient", { enumerable: true, get: function () { return createUIQueryClient_js_1.createUIQueryClient; } });
|
|
6
|
-
var hooks_js_1 = require("./hooks.cjs");
|
|
7
|
-
Object.defineProperty(exports, "useQuery", { enumerable: true, get: function () { return hooks_js_1.useQuery; } });
|
|
8
|
-
Object.defineProperty(exports, "useInfiniteQuery", { enumerable: true, get: function () { return hooks_js_1.useInfiniteQuery; } });
|
|
9
|
-
Object.defineProperty(exports, "useMutation", { enumerable: true, get: function () { return hooks_js_1.useMutation; } });
|
|
10
|
-
//# sourceMappingURL=index.cjs.map
|
package/dist/index.cjs.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;AAAA,oEAA+D;AAAtD,6HAAA,mBAAmB,OAAA;AAC5B,wCAAqE;AAA5D,oGAAA,QAAQ,OAAA;AAAE,4GAAA,gBAAgB,OAAA;AAAE,uGAAA,WAAW,OAAA","sourcesContent":["export { createUIQueryClient } from './createUIQueryClient.js';\nexport { useQuery, useInfiniteQuery, useMutation } from './hooks.js';\n"]}
|
package/dist/index.d.cts
DELETED
package/dist/index.d.cts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.cts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,kCAAiC;AAC/D,OAAO,EAAE,QAAQ,EAAE,gBAAgB,EAAE,WAAW,EAAE,oBAAmB"}
|
package/dist/index.d.mts
DELETED
package/dist/index.d.mts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,kCAAiC;AAC/D,OAAO,EAAE,QAAQ,EAAE,gBAAgB,EAAE,WAAW,EAAE,oBAAmB"}
|
package/dist/index.mjs
DELETED
package/dist/index.mjs.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.mjs","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,kCAAiC;AAC/D,OAAO,EAAE,QAAQ,EAAE,gBAAgB,EAAE,WAAW,EAAE,oBAAmB","sourcesContent":["export { createUIQueryClient } from './createUIQueryClient.js';\nexport { useQuery, useInfiniteQuery, useMutation } from './hooks.js';\n"]}
|
package/dist/loggers.cjs
DELETED
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.createModuleLogger = exports.projectLogger = void 0;
|
|
4
|
-
const utils_1 = require("@metamask/utils");
|
|
5
|
-
Object.defineProperty(exports, "createModuleLogger", { enumerable: true, get: function () { return utils_1.createModuleLogger; } });
|
|
6
|
-
exports.projectLogger = (0, utils_1.createProjectLogger)('react-data-query');
|
|
7
|
-
//# sourceMappingURL=loggers.cjs.map
|
package/dist/loggers.cjs.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"loggers.cjs","sourceRoot":"","sources":["../src/loggers.ts"],"names":[],"mappings":";;;AAAA,2CAA0E;AAIjE,mGAJqB,0BAAkB,OAIrB;AAFd,QAAA,aAAa,GAAG,IAAA,2BAAmB,EAAC,kBAAkB,CAAC,CAAC","sourcesContent":["import { createProjectLogger, createModuleLogger } from '@metamask/utils';\n\nexport const projectLogger = createProjectLogger('react-data-query');\n\nexport { createModuleLogger };\n"]}
|
package/dist/loggers.d.cts
DELETED
package/dist/loggers.d.cts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"loggers.d.cts","sourceRoot":"","sources":["../src/loggers.ts"],"names":[],"mappings":";AAAA,OAAO,EAAuB,kBAAkB,EAAE,wBAAwB;AAE1E,eAAO,MAAM,aAAa,0BAA0C,CAAC;AAErE,OAAO,EAAE,kBAAkB,EAAE,CAAC"}
|
package/dist/loggers.d.mts
DELETED
package/dist/loggers.d.mts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"loggers.d.mts","sourceRoot":"","sources":["../src/loggers.ts"],"names":[],"mappings":";AAAA,OAAO,EAAuB,kBAAkB,EAAE,wBAAwB;AAE1E,eAAO,MAAM,aAAa,0BAA0C,CAAC;AAErE,OAAO,EAAE,kBAAkB,EAAE,CAAC"}
|
package/dist/loggers.mjs
DELETED
package/dist/loggers.mjs.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"loggers.mjs","sourceRoot":"","sources":["../src/loggers.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,kBAAkB,EAAE,wBAAwB;AAE1E,MAAM,CAAC,MAAM,aAAa,GAAG,mBAAmB,CAAC,kBAAkB,CAAC,CAAC;AAErE,OAAO,EAAE,kBAAkB,EAAE,CAAC","sourcesContent":["import { createProjectLogger, createModuleLogger } from '@metamask/utils';\n\nexport const projectLogger = createProjectLogger('react-data-query');\n\nexport { createModuleLogger };\n"]}
|