@herdingbits/trailhead-core 0.0.15 → 0.0.17
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 +2 -1
- package/dist/adapters/types.d.ts +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/shell.d.ts +16 -10
- package/dist/shell.d.ts.map +1 -1
- package/dist/shell.js +70 -37
- package/dist/types/public-api.d.ts +1 -1
- package/dist/types/public-api.d.ts.map +1 -1
- package/dist/types/shell-api.d.ts +45 -12
- package/dist/types/shell-api.d.ts.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -34,7 +34,8 @@ import { YourAdapter } from '@herdingbits/trailhead-your-design-system';
|
|
|
34
34
|
|
|
35
35
|
const shell = new Trailhead({
|
|
36
36
|
adapter: new YourAdapter(),
|
|
37
|
-
|
|
37
|
+
appBasePath: '/app', // URL prefix where SPAs are hosted
|
|
38
|
+
shellUrl: '/app', // URL where shell.js and shell.json are served (defaults to appBasePath)
|
|
38
39
|
apiUrl: 'https://api.example.com'
|
|
39
40
|
});
|
|
40
41
|
```
|
package/dist/adapters/types.d.ts
CHANGED
|
@@ -61,7 +61,7 @@ export interface DesignSystemAdapter {
|
|
|
61
61
|
* Called once at shell startup. Register web component base paths,
|
|
62
62
|
* inject global stylesheets, or perform any other design-system-specific setup.
|
|
63
63
|
*/
|
|
64
|
-
init(
|
|
64
|
+
init(shellUrl: string): Promise<void>;
|
|
65
65
|
/** Feedback implementation backed by this adapter's design system components. */
|
|
66
66
|
feedback: FeedbackAdapter;
|
|
67
67
|
}
|
package/dist/index.d.ts
CHANGED
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AACvC,YAAY,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AACvC,YAAY,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAC9C,YAAY,EAAE,OAAO,EAAE,OAAO,EAAE,UAAU,EAAE,UAAU,EAAE,QAAQ,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC"}
|
package/dist/shell.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Trailhead Core Shell - Design system agnostic orchestration
|
|
3
3
|
*/
|
|
4
|
-
import type { NavItem } from "./types/shell-api.js";
|
|
4
|
+
import type { NavItem, AppEntry } from "./types/shell-api.js";
|
|
5
5
|
import type { DesignSystemAdapter } from "./adapters/types.js";
|
|
6
6
|
/**
|
|
7
7
|
* Configuration passed to the `Trailhead` constructor.
|
|
@@ -9,12 +9,12 @@ import type { DesignSystemAdapter } from "./adapters/types.js";
|
|
|
9
9
|
export interface ShellConfig {
|
|
10
10
|
/** Design system adapter that backs all shell UI — toasts, dialogs, and busy overlays. */
|
|
11
11
|
adapter: DesignSystemAdapter;
|
|
12
|
-
/** URL prefix under which
|
|
13
|
-
|
|
12
|
+
/** URL prefix under which SPAs are hosted (e.g., `"/sample/trailhead"`). Used to strip the prefix from routes, construct SPA asset URLs, and build navigation links. */
|
|
13
|
+
appBasePath?: string;
|
|
14
14
|
/** Base URL prepended to all SPA HTTP requests made via `shell.http`. */
|
|
15
15
|
apiUrl?: string;
|
|
16
|
-
/** URL from which shell static assets (e.g., `
|
|
17
|
-
|
|
16
|
+
/** URL from which the shell bundle and static assets (e.g., `shell.json`) are fetched. Defaults to `appBasePath`. */
|
|
17
|
+
shellUrl?: string;
|
|
18
18
|
}
|
|
19
19
|
/**
|
|
20
20
|
* The Trailhead shell. Bootstraps the micro-frontend host by loading navigation config,
|
|
@@ -29,11 +29,12 @@ export interface ShellConfig {
|
|
|
29
29
|
* ```
|
|
30
30
|
*/
|
|
31
31
|
export declare class Trailhead {
|
|
32
|
-
private
|
|
32
|
+
private apps;
|
|
33
|
+
private nav;
|
|
33
34
|
private routeChangeCallbacks;
|
|
34
|
-
/** URL prefix under which
|
|
35
|
-
readonly
|
|
36
|
-
private readonly
|
|
35
|
+
/** URL prefix under which SPAs are hosted. Empty string when hosted at the root. */
|
|
36
|
+
readonly appBasePath: string;
|
|
37
|
+
private readonly shellUrl;
|
|
37
38
|
/** The active design system adapter supplying UI components to the shell. */
|
|
38
39
|
readonly adapter: DesignSystemAdapter;
|
|
39
40
|
/**
|
|
@@ -44,10 +45,15 @@ export declare class Trailhead {
|
|
|
44
45
|
*/
|
|
45
46
|
constructor(config: ShellConfig);
|
|
46
47
|
/**
|
|
47
|
-
* Returns the
|
|
48
|
+
* Returns the nav menu items loaded from `shell.json`.
|
|
48
49
|
* Adapters call this to render the shell's navigation menu.
|
|
49
50
|
*/
|
|
50
51
|
getNavigation(): NavItem[];
|
|
52
|
+
/**
|
|
53
|
+
* Returns the SPA registry loaded from `shell.json`.
|
|
54
|
+
* Adapters that manage their own routing call this to resolve which app to load.
|
|
55
|
+
*/
|
|
56
|
+
getApps(): AppEntry[];
|
|
51
57
|
/**
|
|
52
58
|
* Initialize shell
|
|
53
59
|
*/
|
package/dist/shell.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"shell.d.ts","sourceRoot":"","sources":["../src/shell.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAY,OAAO,
|
|
1
|
+
{"version":3,"file":"shell.d.ts","sourceRoot":"","sources":["../src/shell.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAY,OAAO,EAAW,QAAQ,EAAiB,MAAM,sBAAsB,CAAC;AAChG,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,qBAAqB,CAAC;AAI/D;;GAEG;AACH,MAAM,WAAW,WAAW;IAC1B,0FAA0F;IAC1F,OAAO,EAAE,mBAAmB,CAAC;IAE7B,wKAAwK;IACxK,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB,yEAAyE;IACzE,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB,qHAAqH;IACrH,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAED;;;;;;;;;;;GAWG;AACH,qBAAa,SAAS;IACpB,OAAO,CAAC,IAAI,CAAkB;IAC9B,OAAO,CAAC,GAAG,CAAiB;IAC5B,OAAO,CAAC,oBAAoB,CAAqC;IAEjE,oFAAoF;IACpF,SAAgB,WAAW,EAAE,MAAM,CAAC;IACpC,OAAO,CAAC,QAAQ,CAAC,QAAQ,CAAS;IAElC,6EAA6E;IAC7E,SAAgB,OAAO,EAAE,mBAAmB,CAAC;IAE7C;;;;;OAKG;gBACS,MAAM,EAAE,WAAW;IAO/B;;;OAGG;IACI,aAAa,IAAI,OAAO,EAAE;IAIjC;;;OAGG;IACI,OAAO,IAAI,QAAQ,EAAE;IAI5B;;OAEG;YACW,IAAI;IAwBlB;;OAEG;YACW,WAAW;IAUzB;;OAEG;IACH,OAAO,CAAC,SAAS;IAiFjB;;OAEG;YACW,cAAc;IAa5B;;OAEG;IACH,OAAO,CAAC,gBAAgB;IAmDxB;;OAEG;IACH,OAAO,CAAC,YAAY;IAMpB;;OAEG;IACH,OAAO,CAAC,QAAQ;IAIhB;;OAEG;IACH,OAAO,CAAC,WAAW;IAsBnB;;OAEG;IACH,OAAO,CAAC,eAAe;IAavB;;OAEG;YACW,UAAU;CAqDzB"}
|
package/dist/shell.js
CHANGED
|
@@ -20,19 +20,27 @@ export class Trailhead {
|
|
|
20
20
|
* @param config - Shell configuration
|
|
21
21
|
*/
|
|
22
22
|
constructor(config) {
|
|
23
|
-
this.
|
|
23
|
+
this.apps = [];
|
|
24
|
+
this.nav = [];
|
|
24
25
|
this.routeChangeCallbacks = [];
|
|
25
|
-
this.
|
|
26
|
-
this.
|
|
26
|
+
this.appBasePath = config.appBasePath || "";
|
|
27
|
+
this.shellUrl = config.shellUrl || this.appBasePath;
|
|
27
28
|
this.adapter = config.adapter;
|
|
28
29
|
this.init(config.apiUrl);
|
|
29
30
|
}
|
|
30
31
|
/**
|
|
31
|
-
* Returns the
|
|
32
|
+
* Returns the nav menu items loaded from `shell.json`.
|
|
32
33
|
* Adapters call this to render the shell's navigation menu.
|
|
33
34
|
*/
|
|
34
35
|
getNavigation() {
|
|
35
|
-
return this.
|
|
36
|
+
return this.nav;
|
|
37
|
+
}
|
|
38
|
+
/**
|
|
39
|
+
* Returns the SPA registry loaded from `shell.json`.
|
|
40
|
+
* Adapters that manage their own routing call this to resolve which app to load.
|
|
41
|
+
*/
|
|
42
|
+
getApps() {
|
|
43
|
+
return this.apps;
|
|
36
44
|
}
|
|
37
45
|
/**
|
|
38
46
|
* Initialize shell
|
|
@@ -59,7 +67,7 @@ export class Trailhead {
|
|
|
59
67
|
*/
|
|
60
68
|
async initAdapter() {
|
|
61
69
|
try {
|
|
62
|
-
await this.adapter.init(this.
|
|
70
|
+
await this.adapter.init(this.shellUrl);
|
|
63
71
|
console.log(`[Trailhead] Initialized ${this.adapter.name} adapter v${this.adapter.version}`);
|
|
64
72
|
}
|
|
65
73
|
catch (error) {
|
|
@@ -149,12 +157,15 @@ export class Trailhead {
|
|
|
149
157
|
*/
|
|
150
158
|
async loadNavigation() {
|
|
151
159
|
try {
|
|
152
|
-
const response = await fetch(`${this.
|
|
153
|
-
|
|
160
|
+
const response = await fetch(`${this.shellUrl}/shell.json`);
|
|
161
|
+
const manifest = await response.json();
|
|
162
|
+
this.apps = manifest.apps ?? [];
|
|
163
|
+
this.nav = manifest.nav ?? [];
|
|
154
164
|
}
|
|
155
165
|
catch (error) {
|
|
156
|
-
console.error("Failed to load
|
|
157
|
-
this.
|
|
166
|
+
console.error("Failed to load shell.json:", error);
|
|
167
|
+
this.apps = [];
|
|
168
|
+
this.nav = [];
|
|
158
169
|
}
|
|
159
170
|
}
|
|
160
171
|
/**
|
|
@@ -164,25 +175,47 @@ export class Trailhead {
|
|
|
164
175
|
const nav = document.getElementById("shell-navigation");
|
|
165
176
|
if (!nav)
|
|
166
177
|
return;
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
178
|
+
const isExternal = (href) => /^https?:\/\/|^\/\//.test(href);
|
|
179
|
+
const renderLink = (item, isChild = false) => {
|
|
180
|
+
const external = isExternal(item.href);
|
|
181
|
+
const fullHref = external ? item.href : `${this.appBasePath}${item.href}`;
|
|
182
|
+
return `<a href="${fullHref}"
|
|
183
|
+
class="shell-nav-item${isChild ? " shell-nav-item-child" : ""}"
|
|
184
|
+
data-path="${item.href}"
|
|
185
|
+
data-external="${external}">
|
|
186
|
+
<i class="shell-icon shell-icon-${item.icon ?? ""}"></i>
|
|
174
187
|
<span class="shell-nav-label">${item.label}</span>
|
|
175
|
-
</a
|
|
176
|
-
|
|
188
|
+
</a>`;
|
|
189
|
+
};
|
|
190
|
+
nav.innerHTML = [...this.nav]
|
|
191
|
+
.sort((a, b) => a.order - b.order)
|
|
192
|
+
.map((item) => {
|
|
193
|
+
switch (item.type) {
|
|
194
|
+
case "link":
|
|
195
|
+
return renderLink(item);
|
|
196
|
+
case "section":
|
|
197
|
+
return `<div class="shell-nav-section">
|
|
198
|
+
<span class="shell-nav-section-header">
|
|
199
|
+
<i class="shell-icon shell-icon-${item.icon ?? ""}"></i>
|
|
200
|
+
<span class="shell-nav-label">${item.label}</span>
|
|
201
|
+
</span>
|
|
202
|
+
${[...item.children].sort((a, b) => a.order - b.order).map((c) => renderLink(c, true)).join("")}
|
|
203
|
+
</div>`;
|
|
204
|
+
case "divider":
|
|
205
|
+
return `<hr class="shell-nav-divider" />`;
|
|
206
|
+
}
|
|
207
|
+
})
|
|
177
208
|
.join("");
|
|
178
209
|
nav.querySelectorAll("a").forEach((link) => {
|
|
179
|
-
link.
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
210
|
+
if (link.getAttribute("data-external") !== "true") {
|
|
211
|
+
link.addEventListener("click", (e) => {
|
|
212
|
+
e.preventDefault();
|
|
213
|
+
const path = link.getAttribute("data-path");
|
|
214
|
+
if (path) {
|
|
215
|
+
this.navigate(path);
|
|
216
|
+
}
|
|
217
|
+
});
|
|
218
|
+
}
|
|
186
219
|
});
|
|
187
220
|
}
|
|
188
221
|
/**
|
|
@@ -197,26 +230,26 @@ export class Trailhead {
|
|
|
197
230
|
* Navigate to path
|
|
198
231
|
*/
|
|
199
232
|
navigate(path) {
|
|
200
|
-
window.location.href = this.
|
|
233
|
+
window.location.href = this.appBasePath + path;
|
|
201
234
|
}
|
|
202
235
|
/**
|
|
203
236
|
* Handle route change
|
|
204
237
|
*/
|
|
205
238
|
handleRoute() {
|
|
206
239
|
let path = window.location.pathname;
|
|
207
|
-
if (this.
|
|
208
|
-
path = path.substring(this.
|
|
240
|
+
if (this.appBasePath && path.startsWith(this.appBasePath)) {
|
|
241
|
+
path = path.substring(this.appBasePath.length) || "/";
|
|
209
242
|
}
|
|
210
|
-
const
|
|
211
|
-
if (
|
|
243
|
+
const app = this.apps.find((entry) => path.startsWith(entry.basePath));
|
|
244
|
+
if (app) {
|
|
212
245
|
// Skip loading if app is already mounted (dev mode)
|
|
213
246
|
const shellContent = document.getElementById("shell-content");
|
|
214
247
|
const rootElement = shellContent?.querySelector("#root");
|
|
215
248
|
const isAlreadyMounted = rootElement && rootElement.children.length > 0;
|
|
216
249
|
if (!isAlreadyMounted) {
|
|
217
|
-
this.loadPlugin(
|
|
250
|
+
this.loadPlugin(app.src, app.basePath);
|
|
218
251
|
}
|
|
219
|
-
this.updateActiveNav(
|
|
252
|
+
this.updateActiveNav(app.basePath);
|
|
220
253
|
}
|
|
221
254
|
}
|
|
222
255
|
/**
|
|
@@ -244,19 +277,19 @@ export class Trailhead {
|
|
|
244
277
|
return;
|
|
245
278
|
root.innerHTML = `<div class="shell-loading">Loading...</div>`;
|
|
246
279
|
const isDev = window.__SHELL_DEV__ === true;
|
|
247
|
-
const appBasePath = this.
|
|
280
|
+
const appBasePath = this.appBasePath + appPath;
|
|
248
281
|
try {
|
|
249
282
|
if (isDev) {
|
|
250
283
|
// ✅ DEV PATH — Vite-native, HMR-compatible
|
|
251
284
|
const mod = await import(
|
|
252
285
|
/* @vite-ignore */
|
|
253
|
-
`${this.
|
|
286
|
+
`${this.appBasePath}${appPath}/src/index.ts`);
|
|
254
287
|
root.innerHTML = "";
|
|
255
288
|
mod.AppMount(root, appBasePath);
|
|
256
289
|
return;
|
|
257
290
|
}
|
|
258
|
-
const pluginUrl = `${this.
|
|
259
|
-
const pluginCss = `${this.
|
|
291
|
+
const pluginUrl = `${this.appBasePath}${appPath}/app.js`;
|
|
292
|
+
const pluginCss = `${this.appBasePath}${appPath}/${appName}.css`;
|
|
260
293
|
// Load CSS
|
|
261
294
|
const link = document.createElement("link");
|
|
262
295
|
link.rel = "stylesheet";
|
|
@@ -2,5 +2,5 @@
|
|
|
2
2
|
* Public Shell API - Only these types are exposed to plugin applications
|
|
3
3
|
* This file explicitly defines what's public vs internal
|
|
4
4
|
*/
|
|
5
|
-
export type { ShellAPI, ShellPlugin, FeedbackAPI, AlertVariant, HttpAPI, RequestOptions, Result, SuccessResult, ErrorResult, HttpError, NavigationAPI, NavItem, } from "./shell-api.js";
|
|
5
|
+
export type { ShellAPI, ShellPlugin, FeedbackAPI, AlertVariant, HttpAPI, RequestOptions, Result, SuccessResult, ErrorResult, HttpError, NavigationAPI, NavItem, NavLink, NavSection, NavDivider, AppEntry, ShellManifest, } from "./shell-api.js";
|
|
6
6
|
//# sourceMappingURL=public-api.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"public-api.d.ts","sourceRoot":"","sources":["../../src/types/public-api.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,YAAY,EACV,QAAQ,EACR,WAAW,EACX,WAAW,EACX,YAAY,EACZ,OAAO,EACP,cAAc,EACd,MAAM,EACN,aAAa,EACb,WAAW,EACX,SAAS,EACT,aAAa,EACb,OAAO,
|
|
1
|
+
{"version":3,"file":"public-api.d.ts","sourceRoot":"","sources":["../../src/types/public-api.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,YAAY,EACV,QAAQ,EACR,WAAW,EACX,WAAW,EACX,YAAY,EACZ,OAAO,EACP,cAAc,EACd,MAAM,EACN,aAAa,EACb,WAAW,EACX,SAAS,EACT,aAAa,EACb,OAAO,EACP,OAAO,EACP,UAAU,EACV,UAAU,EACV,QAAQ,EACR,aAAa,GACd,MAAM,gBAAgB,CAAC"}
|
|
@@ -448,25 +448,58 @@ export interface NavigationAPI {
|
|
|
448
448
|
onRouteChange(callback: (path: string) => void): () => void;
|
|
449
449
|
}
|
|
450
450
|
/**
|
|
451
|
-
*
|
|
452
|
-
*
|
|
453
|
-
* Defines a navigation menu item in `navigation.json`.
|
|
451
|
+
* SPA registration entry in `shell.json`.
|
|
452
|
+
* Describes a hosted application — where it lives and how to load it.
|
|
454
453
|
*/
|
|
455
|
-
export interface
|
|
456
|
-
/**
|
|
454
|
+
export interface AppEntry {
|
|
455
|
+
/** Unique identifier for this SPA (used in logs and as the CSS filename stem). */
|
|
457
456
|
id: string;
|
|
458
|
-
/**
|
|
459
|
-
|
|
460
|
-
/**
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
457
|
+
/** URL path prefix at which this SPA is mounted (e.g., `"/demo"`). Shell loads the app when the current URL starts with this value. */
|
|
458
|
+
basePath: string;
|
|
459
|
+
/** Asset directory name. Shell resolves `<appBasePath>/<src>/app.js` and `<appBasePath>/<src>/<src>.css`. */
|
|
460
|
+
src: string;
|
|
461
|
+
}
|
|
462
|
+
/**
|
|
463
|
+
* Parsed structure of `shell.json`.
|
|
464
|
+
*/
|
|
465
|
+
export interface ShellManifest {
|
|
466
|
+
apps: AppEntry[];
|
|
467
|
+
nav: NavItem[];
|
|
468
|
+
}
|
|
469
|
+
/** A leaf nav item that links to a URL or SPA route. */
|
|
470
|
+
export interface NavLink {
|
|
471
|
+
type: 'link';
|
|
472
|
+
/** Visible label rendered in the nav. */
|
|
464
473
|
label: string;
|
|
474
|
+
/** Icon identifier passed to the adapter's icon component. Naming convention is design-system-specific. */
|
|
475
|
+
icon?: string;
|
|
465
476
|
/** Lower numbers appear earlier in the menu. */
|
|
466
477
|
order: number;
|
|
467
|
-
/**
|
|
478
|
+
/** Absolute URL (browser handles navigation; shell does not intercept) or relative path (shell loads the matching SPA). */
|
|
479
|
+
href: string;
|
|
480
|
+
/** Called on each render to get a live count shown as a badge on this item. */
|
|
468
481
|
badge?: () => number;
|
|
469
482
|
}
|
|
483
|
+
/** A section header that groups a set of child links. Maximum nesting depth is one level. */
|
|
484
|
+
export interface NavSection {
|
|
485
|
+
type: 'section';
|
|
486
|
+
/** Visible label for the section header. */
|
|
487
|
+
label: string;
|
|
488
|
+
/** Icon identifier for the section header. */
|
|
489
|
+
icon?: string;
|
|
490
|
+
/** Lower numbers appear earlier in the menu. */
|
|
491
|
+
order: number;
|
|
492
|
+
/** Child link items. Only `NavLink` is allowed here — no nested sections. */
|
|
493
|
+
children: NavLink[];
|
|
494
|
+
}
|
|
495
|
+
/** A visual divider rendered between nav groups. */
|
|
496
|
+
export interface NavDivider {
|
|
497
|
+
type: 'divider';
|
|
498
|
+
/** Lower numbers appear earlier in the menu. */
|
|
499
|
+
order: number;
|
|
500
|
+
}
|
|
501
|
+
/** Discriminated union of all nav item types. */
|
|
502
|
+
export type NavItem = NavLink | NavSection | NavDivider;
|
|
470
503
|
/**
|
|
471
504
|
* Global window extension
|
|
472
505
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"shell-api.d.ts","sourceRoot":"","sources":["../../src/types/shell-api.ts"],"names":[],"mappings":"AAAA;;;;;;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AAE,SAAS,CAAC;IAChB,gDAAgD;IAChD,KAAK,EAAE,MAAM,CAAC;CACf;AAED,iDAAiD;AACjD,MAAM,MAAM,OAAO,GAAG,OAAO,GAAG,UAAU,GAAG,UAAU,CAAC;AAExD;;;;GAIG;AACH,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,MAAM;QACd,gDAAgD;QAChD,KAAK,EAAE,QAAQ,CAAC;QAEhB,wCAAwC;QACxC,QAAQ,CAAC,EAAE,CAAC,IAAI,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,KAAK,IAAI,CAAC;KAC1D;CACF"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@herdingbits/trailhead-core",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.17",
|
|
4
4
|
"description": "Simple application shell that orchestrates multiple SPAs. No webpack magic, just the browser's native module system.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|