@ebitex/content-sdk 1.1.326 → 1.1.327
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/react/routeData.d.ts +4 -1
- package/dist/react/routeData.d.ts.map +1 -1
- package/dist/react/routeData.js +12 -6
- package/dist/react/routeData.js.map +1 -1
- package/dist/routeData.d.ts +12 -7
- package/dist/routeData.d.ts.map +1 -1
- package/dist/routeData.js +18 -19
- package/dist/routeData.js.map +1 -1
- package/package.json +1 -1
|
@@ -31,7 +31,7 @@ export interface RouteDataBoundaryProps {
|
|
|
31
31
|
* Mounted by `<Experience routeData>` inside the route context. Loads each definition whose tag
|
|
32
32
|
* matches the delivered route, once per parameter set; asks the route to render the host's
|
|
33
33
|
* not-found when a loader answers `NotFound`; replaces the page with the provider's error panel
|
|
34
|
-
* when a loader throws. With no route on the result (an ordinary page, an older server) no loader
|
|
34
|
+
* when a loader throws. A definition whose tag does not match is skipped without error. With no route on the result (an ordinary page, an older server) no loader
|
|
35
35
|
* runs, and the page renders as it would without the boundary.
|
|
36
36
|
*/
|
|
37
37
|
export declare function RouteDataBoundary({ definitions, initial, route, locale, path, errorComponent, children }: RouteDataBoundaryProps): ReactNode;
|
|
@@ -47,6 +47,9 @@ export declare function RouteDataBoundary({ definitions, initial, route, locale,
|
|
|
47
47
|
* ```
|
|
48
48
|
*
|
|
49
49
|
* `definition` must be one of the list given to `<Experience routeData>`; anything else throws.
|
|
50
|
+
* When the page has a route whose tag is not the definition's (or has none), reading it throws in
|
|
51
|
+
* development, naming both tags; in production it reports `notFound`. On a page with no route it
|
|
52
|
+
* reports `notFound` in both modes. Listing a definition no section reads on such a page is fine.
|
|
50
53
|
*/
|
|
51
54
|
export declare function useRouteData<TDefinition extends AnyRouteDataDefinition>(definition: TDefinition): RouteDataState<RouteDataOf<TDefinition>>;
|
|
52
55
|
//# sourceMappingURL=routeData.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"routeData.d.ts","sourceRoot":"","sources":["../../src/react/routeData.tsx"],"names":[],"mappings":"AAAA,OAAO,EAA+E,KAAK,aAAa,EAAE,KAAK,SAAS,EAAE,MAAM,OAAO,CAAA;
|
|
1
|
+
{"version":3,"file":"routeData.d.ts","sourceRoot":"","sources":["../../src/react/routeData.tsx"],"names":[],"mappings":"AAAA,OAAO,EAA+E,KAAK,aAAa,EAAE,KAAK,SAAS,EAAE,MAAM,OAAO,CAAA;AAGvI,OAAO,EAML,KAAK,sBAAsB,EAE3B,KAAK,WAAW,EAChB,KAAK,iBAAiB,EACvB,MAAM,iBAAiB,CAAA;AACxB,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,aAAa,CAAA;AAE9C,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,aAAa,CAAA;AAGpD;;;;GAIG;AACH,MAAM,MAAM,cAAc,CAAC,KAAK,IAC5B;IAAE,MAAM,EAAE,SAAS,CAAA;CAAE,GACrB;IAAE,MAAM,EAAE,OAAO,CAAC;IAAC,KAAK,EAAE,KAAK,CAAA;CAAE,GACjC;IAAE,MAAM,EAAE,UAAU,CAAA;CAAE,GACtB;IAAE,MAAM,EAAE,OAAO,CAAC;IAAC,KAAK,EAAE,OAAO,CAAA;CAAE,CAAA;AAqKvC,MAAM,WAAW,sBAAsB;IACrC,WAAW,EAAE,SAAS,sBAAsB,EAAE,CAAA;IAC9C,OAAO,EAAE,iBAAiB,GAAG,SAAS,CAAA;IACtC,KAAK,EAAE,WAAW,GAAG,SAAS,CAAA;IAC9B,MAAM,EAAE,MAAM,GAAG,SAAS,CAAA;IAC1B,IAAI,EAAE,MAAM,GAAG,SAAS,CAAA;IACxB,cAAc,EAAE,aAAa,CAAC,iBAAiB,CAAC,GAAG,SAAS,CAAA;IAC5D,QAAQ,EAAE,SAAS,CAAA;CACpB;AAED;;;;;;GAMG;AACH,wBAAgB,iBAAiB,CAAC,EAAE,WAAW,EAAE,OAAO,EAAE,KAAK,EAAE,MAAM,EAAE,IAAI,EAAE,cAAc,EAAE,QAAQ,EAAE,EAAE,sBAAsB,GAAG,SAAS,CAuD5I;AAED;;;;;;;;;;;;;;;GAeG;AACH,wBAAgB,YAAY,CAAC,WAAW,SAAS,sBAAsB,EAAE,UAAU,EAAE,WAAW,GAAG,cAAc,CAAC,WAAW,CAAC,WAAW,CAAC,CAAC,CAmB1I"}
|
package/dist/react/routeData.js
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
2
|
import { createContext, useContext, useEffect, useMemo, useRef, useSyncExternalStore } from 'react';
|
|
3
|
+
import { isDevelopment } from '../environment.js';
|
|
3
4
|
import { isAbortError } from '../errors.js';
|
|
4
|
-
import {
|
|
5
|
+
import { assertDistinctContexts, describeMismatch, isNotFound, matchesRoute, paramsKey, } from '../routeData.js';
|
|
5
6
|
import { useContentContext } from './ContentProvider.js';
|
|
6
7
|
import { useRoute } from './routeContext.js';
|
|
7
8
|
const LOADING = Object.freeze({ status: 'loading' });
|
|
@@ -140,13 +141,13 @@ function idOf(definition) {
|
|
|
140
141
|
* Mounted by `<Experience routeData>` inside the route context. Loads each definition whose tag
|
|
141
142
|
* matches the delivered route, once per parameter set; asks the route to render the host's
|
|
142
143
|
* not-found when a loader answers `NotFound`; replaces the page with the provider's error panel
|
|
143
|
-
* when a loader throws. With no route on the result (an ordinary page, an older server) no loader
|
|
144
|
+
* when a loader throws. A definition whose tag does not match is skipped without error. With no route on the result (an ordinary page, an older server) no loader
|
|
144
145
|
* runs, and the page renders as it would without the boundary.
|
|
145
146
|
*/
|
|
146
147
|
export function RouteDataBoundary({ definitions, initial, route, locale, path, errorComponent, children }) {
|
|
147
148
|
assertDistinctContexts(definitions);
|
|
148
|
-
//
|
|
149
|
-
const applicableList = definitions.filter((definition) =>
|
|
149
|
+
// A definition for another address is skipped, never an error: the development check is at the read (useRouteData).
|
|
150
|
+
const applicableList = definitions.filter((definition) => matchesRoute(definition, route));
|
|
150
151
|
const params = route?.params;
|
|
151
152
|
const entryKey = `${params === undefined ? '' : paramsKey(params)}|${locale ?? ''}`;
|
|
152
153
|
const definitionsKey = applicableList.map(idOf).join(',');
|
|
@@ -173,10 +174,10 @@ export function RouteDataBoundary({ definitions, initial, route, locale, path, e
|
|
|
173
174
|
}, 0);
|
|
174
175
|
};
|
|
175
176
|
}, [store, entryKey, definitionsKey, locale]);
|
|
176
|
-
const value = useMemo(() => ({ store, entryKey, listed: new Set(definitions), applicable: new Set(applicableList) }),
|
|
177
|
+
const value = useMemo(() => ({ store, entryKey, route, listed: new Set(definitions), applicable: new Set(applicableList) }),
|
|
177
178
|
// The sets are rebuilt only when the definitions (by identity) or the key change, not on each parent render.
|
|
178
179
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
179
|
-
[store, entryKey, listedKey, definitionsKey]);
|
|
180
|
+
[store, entryKey, route?.pattern, route?.context, listedKey, definitionsKey]);
|
|
180
181
|
const failure = useSyncExternalStore(store.subscribe, () => store.failure(entryKey), () => store.failure(entryKey));
|
|
181
182
|
const anyNotFound = useSyncExternalStore(store.subscribe, () => store.hasNotFound(entryKey), () => store.hasNotFound(entryKey));
|
|
182
183
|
const { notFound } = useRoute();
|
|
@@ -203,6 +204,9 @@ export function RouteDataBoundary({ definitions, initial, route, locale, path, e
|
|
|
203
204
|
* ```
|
|
204
205
|
*
|
|
205
206
|
* `definition` must be one of the list given to `<Experience routeData>`; anything else throws.
|
|
207
|
+
* When the page has a route whose tag is not the definition's (or has none), reading it throws in
|
|
208
|
+
* development, naming both tags; in production it reports `notFound`. On a page with no route it
|
|
209
|
+
* reports `notFound` in both modes. Listing a definition no section reads on such a page is fine.
|
|
206
210
|
*/
|
|
207
211
|
export function useRouteData(definition) {
|
|
208
212
|
const context = useContext(RouteDataContext);
|
|
@@ -213,6 +217,8 @@ export function useRouteData(definition) {
|
|
|
213
217
|
throw new Error(`@ebitex/content-sdk/react: useRouteData was given a definition for "${definition.context}" that is not in this page's <Experience routeData>. Add it to the list.`);
|
|
214
218
|
}
|
|
215
219
|
const applies = context.applicable.has(definition);
|
|
220
|
+
if (!applies && context.route !== undefined && isDevelopment())
|
|
221
|
+
throw new Error(describeMismatch(definition, context.route));
|
|
216
222
|
const state = useSyncExternalStore(context.store.subscribe, () => (applies ? context.store.read(definition, context.entryKey) : NOT_FOUND_STATE), () => (applies ? context.store.read(definition, context.entryKey) : NOT_FOUND_STATE));
|
|
217
223
|
return state;
|
|
218
224
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"routeData.js","sourceRoot":"","sources":["../../src/react/routeData.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,aAAa,EAAE,UAAU,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,EAAE,oBAAoB,EAAsC,MAAM,OAAO,CAAA;AACvI,OAAO,EAAE,YAAY,EAAE,MAAM,cAAc,CAAA;AAC3C,OAAO,EACL,
|
|
1
|
+
{"version":3,"file":"routeData.js","sourceRoot":"","sources":["../../src/react/routeData.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,aAAa,EAAE,UAAU,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,EAAE,oBAAoB,EAAsC,MAAM,OAAO,CAAA;AACvI,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAA;AACjD,OAAO,EAAE,YAAY,EAAE,MAAM,cAAc,CAAA;AAC3C,OAAO,EACL,sBAAsB,EACtB,gBAAgB,EAChB,UAAU,EACV,YAAY,EACZ,SAAS,GAKV,MAAM,iBAAiB,CAAA;AAExB,OAAO,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAA;AAExD,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAA;AAe5C,MAAM,OAAO,GAAY,MAAM,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,SAAkB,EAAE,CAAC,CAAA;AACtE,MAAM,eAAe,GAAY,MAAM,CAAC,MAAM,CAAC,EAAE,MAAM,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OAAO,0EAA0E,CAAC,CAAA;IACtL,CAAC;IAED,MAAM,OAAO,GAAG,OAAO,CAAC,UAAU,CAAC,GAAG,CAAC,UAAU,CAAC,CAAA;IAClD,IAAI,CAAC,OAAO,IAAI,OAAO,CAAC,KAAK,KAAK,SAAS,IAAI,aAAa,EAAE;QAAE,MAAM,IAAI,KAAK,CAAC,gBAAgB,CAAC,UAAU,EAAE,OAAO,CAAC,KAAK,CAAC,CAAC,CAAA;IAC5H,MAAM,KAAK,GAAG,oBAAoB,CAChC,OAAO,CAAC,KAAK,CAAC,SAAS,EACvB,GAAG,EAAE,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,CAAC,UAAU,EAAE,OAAO,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,eAAe,CAAC,EACpF,GAAG,EAAE,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,CAAC,UAAU,EAAE,OAAO,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,eAAe,CAAC,CACrF,CAAA;IAED,OAAO,KAAiD,CAAA;AAC1D,CAAC"}
|
package/dist/routeData.d.ts
CHANGED
|
@@ -57,19 +57,24 @@ export type RouteDataOf<TDefinition> = TDefinition extends RouteDataDefinition<s
|
|
|
57
57
|
* `load` receives the route's parameters (annotate them to type them: `({ slug }: { slug: string })`)
|
|
58
58
|
* and returns the data, or {@link NotFound}. It runs once per parameter set however many sections read it.
|
|
59
59
|
* The tag is the contract between this loader and the page: the page's parameter node must carry
|
|
60
|
-
* the same one, and a loader whose tag differs from the delivered one
|
|
60
|
+
* the same one, and in development a section that reads a loader whose tag differs from the delivered one throws.
|
|
61
61
|
*/
|
|
62
62
|
export declare function defineRouteData<TContext extends string, TData, TParams extends Record<string, string> = Record<string, string>>(definition: {
|
|
63
63
|
context: TContext;
|
|
64
64
|
load: (params: TParams, options: RouteDataLoadOptions) => Promise<TData | NotFound>;
|
|
65
65
|
}): RouteDataDefinition<TContext, TData, TParams>;
|
|
66
66
|
/**
|
|
67
|
-
*
|
|
68
|
-
*
|
|
69
|
-
*
|
|
70
|
-
* tags, and is skipped in production.
|
|
67
|
+
* True when the definition applies to the delivered route: the page has a route and its tag is the
|
|
68
|
+
* definition's. Pure: never throws, in either mode, so a list of definitions can be filtered with
|
|
69
|
+
* it on any page (a loader listed for one address is simply skipped on another).
|
|
71
70
|
*/
|
|
72
|
-
export declare function
|
|
71
|
+
export declare function matchesRoute(definition: AnyRouteDataDefinition, route: RouteResult | undefined): boolean;
|
|
72
|
+
/**
|
|
73
|
+
* The development message for a definition that does not match a route that exists, naming both
|
|
74
|
+
* tags. Thrown by `useRouteData` when a section reads a definition its page does not carry the tag
|
|
75
|
+
* for: the mistake is in the section that reads it, not in listing the definition.
|
|
76
|
+
*/
|
|
77
|
+
export declare function describeMismatch(definition: AnyRouteDataDefinition, route: RouteResult): string;
|
|
73
78
|
/** Throws when two definitions share a tag, since the values are keyed by it. */
|
|
74
79
|
export declare function assertDistinctContexts(definitions: readonly AnyRouteDataDefinition[]): void;
|
|
75
80
|
/**
|
|
@@ -102,7 +107,7 @@ export declare function paramsKey(params: Record<string, string>): string;
|
|
|
102
107
|
* ```
|
|
103
108
|
*
|
|
104
109
|
* Only definitions whose tag matches the route's run; with no route (an ordinary page) nothing
|
|
105
|
-
* runs. A loader's own errors reject this promise.
|
|
110
|
+
* runs. A definition for another address is skipped, never an error, in either mode. A loader's own errors reject this promise.
|
|
106
111
|
*/
|
|
107
112
|
export declare function loadRouteData(definitions: readonly AnyRouteDataDefinition[], route: RouteResult | undefined, options?: {
|
|
108
113
|
locale?: string;
|
package/dist/routeData.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"routeData.d.ts","sourceRoot":"","sources":["../src/routeData.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"routeData.d.ts","sourceRoot":"","sources":["../src/routeData.ts"],"names":[],"mappings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,EAAE,WAAW,CAAA;CAAO,GACtD,OAAO,CAAC,eAAe,CAAC,CAoB1B"}
|
package/dist/routeData.js
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { isDevelopment } from './environment.js';
|
|
2
1
|
/**
|
|
3
2
|
* Data that belongs to a parameterised page rather than to any one section on it. A route's
|
|
4
3
|
* parameter (`/products/{key}`) names something the Content tree does not hold, so the host says
|
|
@@ -35,28 +34,28 @@ export function isNotFound(value) {
|
|
|
35
34
|
* `load` receives the route's parameters (annotate them to type them: `({ slug }: { slug: string })`)
|
|
36
35
|
* and returns the data, or {@link NotFound}. It runs once per parameter set however many sections read it.
|
|
37
36
|
* The tag is the contract between this loader and the page: the page's parameter node must carry
|
|
38
|
-
* the same one, and a loader whose tag differs from the delivered one
|
|
37
|
+
* the same one, and in development a section that reads a loader whose tag differs from the delivered one throws.
|
|
39
38
|
*/
|
|
40
39
|
export function defineRouteData(definition) {
|
|
41
40
|
return Object.freeze({ context: definition.context, load: definition.load });
|
|
42
41
|
}
|
|
43
42
|
/**
|
|
44
|
-
*
|
|
45
|
-
*
|
|
46
|
-
*
|
|
47
|
-
* tags, and is skipped in production.
|
|
43
|
+
* True when the definition applies to the delivered route: the page has a route and its tag is the
|
|
44
|
+
* definition's. Pure: never throws, in either mode, so a list of definitions can be filtered with
|
|
45
|
+
* it on any page (a loader listed for one address is simply skipped on another).
|
|
48
46
|
*/
|
|
49
|
-
export function
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
}
|
|
59
|
-
return
|
|
47
|
+
export function matchesRoute(definition, route) {
|
|
48
|
+
return route !== undefined && route.context === definition.context;
|
|
49
|
+
}
|
|
50
|
+
/**
|
|
51
|
+
* The development message for a definition that does not match a route that exists, naming both
|
|
52
|
+
* tags. Thrown by `useRouteData` when a section reads a definition its page does not carry the tag
|
|
53
|
+
* for: the mistake is in the section that reads it, not in listing the definition.
|
|
54
|
+
*/
|
|
55
|
+
export function describeMismatch(definition, route) {
|
|
56
|
+
const delivered = route.context === undefined ? 'no route context tag' : `the route context tag "${route.context}"`;
|
|
57
|
+
return (`@ebitex/content-sdk: the route data definition for "${definition.context}" does not match this page: its address "${route.pattern}" carries ${delivered}. ` +
|
|
58
|
+
'Give the parameter node the tag the loader names, or read this loader only in sections placed on the pages it belongs to.');
|
|
60
59
|
}
|
|
61
60
|
/** Throws when two definitions share a tag, since the values are keyed by it. */
|
|
62
61
|
export function assertDistinctContexts(definitions) {
|
|
@@ -84,13 +83,13 @@ export function paramsKey(params) {
|
|
|
84
83
|
* ```
|
|
85
84
|
*
|
|
86
85
|
* Only definitions whose tag matches the route's run; with no route (an ordinary page) nothing
|
|
87
|
-
* runs. A loader's own errors reject this promise.
|
|
86
|
+
* runs. A definition for another address is skipped, never an error, in either mode. A loader's own errors reject this promise.
|
|
88
87
|
*/
|
|
89
88
|
export async function loadRouteData(definitions, route, options = {}) {
|
|
90
89
|
assertDistinctContexts(definitions);
|
|
91
90
|
const signal = options.signal ?? new AbortController().signal;
|
|
92
91
|
const loaded = { notFound: false, values: {}, missing: [] };
|
|
93
|
-
const applicable = definitions.filter((definition) =>
|
|
92
|
+
const applicable = definitions.filter((definition) => matchesRoute(definition, route));
|
|
94
93
|
await Promise.all(applicable.map(async (definition) => {
|
|
95
94
|
const result = await definition.load(route?.params ?? {}, { locale: options.locale, signal });
|
|
96
95
|
if (isNotFound(result)) {
|
package/dist/routeData.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"routeData.js","sourceRoot":"","sources":["../src/routeData.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"routeData.js","sourceRoot":"","sources":["../src/routeData.ts"],"names":[],"mappings":"AAEA;;;;;;;;GAQG;AAEH,MAAM,SAAS,GAAG,MAAM,CAAC,GAAG,CAAC,mCAAmC,CAAC,CAAA;AAOjE;;;;GAIG;AACH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AAM,EAAE,CAAC,CAAA;QACtL,IAAI,UAAU,CAAC,MAAM,CAAC,EAAE,CAAC;YACvB,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC,UAAU,CAAC,OAAO,CAAC,CAAA;YACvC,MAAM,CAAC,QAAQ,GAAG,IAAI,CAAA;QACxB,CAAC;aAAM,CAAC;YACN,MAAM,CAAC,MAAM,CAAC,UAAU,CAAC,OAAO,CAAC,GAAG,MAAM,CAAA;QAC5C,CAAC;IACH,CAAC,CAAC,CACH,CAAA;IAED,MAAM,CAAC,OAAO,CAAC,IAAI,EAAE,CAAA;IACrB,OAAO,MAAM,CAAA;AACf,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ebitex/content-sdk",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.327",
|
|
4
4
|
"description": "The client for the ebitex Content Delivery API: typed endpoints, React rendering, sitemaps, live preview and locale addressing, so a site does not maintain its own.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"ebitex",
|