@esmx/router 3.0.0-rc.57 → 3.0.0-rc.58

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/router.d.ts CHANGED
@@ -12,6 +12,7 @@ export declare class Router {
12
12
  readonly microApp: MicroApp;
13
13
  readonly transition: RouteTransition;
14
14
  get route(): Route;
15
+ get context(): Record<string | symbol, unknown>;
15
16
  get root(): string | HTMLElement;
16
17
  get mode(): RouterMode;
17
18
  get base(): URL;
package/dist/router.mjs CHANGED
@@ -41,6 +41,9 @@ export class Router {
41
41
  }
42
42
  return route;
43
43
  }
44
+ get context() {
45
+ return this.parsedOptions.context;
46
+ }
44
47
  get root() {
45
48
  return this.parsedOptions.root;
46
49
  }
@@ -226,6 +229,7 @@ export class Router {
226
229
  justifyContent: "center"
227
230
  },
228
231
  ...this.options,
232
+ context: this.parsedOptions.context,
229
233
  mode: RouterMode.memory,
230
234
  root: void 0,
231
235
  ...layerOptions.routerOptions,
package/package.json CHANGED
@@ -39,7 +39,7 @@
39
39
  "unbuild": "3.6.0",
40
40
  "vitest": "3.2.4"
41
41
  },
42
- "version": "3.0.0-rc.57",
42
+ "version": "3.0.0-rc.58",
43
43
  "type": "module",
44
44
  "private": false,
45
45
  "exports": {
@@ -58,5 +58,5 @@
58
58
  "template",
59
59
  "public"
60
60
  ],
61
- "gitHead": "bb3fbfa6de4906b7e98bc387c3e1d8e0c3164ac7"
61
+ "gitHead": "3155bf0f560b5395d476d1f446d59bc8c3729cb9"
62
62
  }
package/src/router.ts CHANGED
@@ -40,6 +40,10 @@ export class Router {
40
40
  return route;
41
41
  }
42
42
 
43
+ public get context() {
44
+ return this.parsedOptions.context;
45
+ }
46
+
43
47
  public get root() {
44
48
  return this.parsedOptions.root;
45
49
  }
@@ -257,6 +261,7 @@ export class Router {
257
261
  justifyContent: 'center'
258
262
  },
259
263
  ...this.options,
264
+ context: this.parsedOptions.context,
260
265
  mode: RouterMode.memory,
261
266
  root: undefined,
262
267
  ...layerOptions.routerOptions,