@real-router/types 0.22.0 → 0.23.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/cjs/index.d.ts +4 -3
- package/dist/cjs/metafile-cjs.json +1 -1
- package/dist/esm/index.d.mts +4 -3
- package/package.json +1 -1
- package/src/base.ts +3 -3
- package/src/router.ts +2 -0
package/dist/cjs/index.d.ts
CHANGED
|
@@ -47,11 +47,11 @@ interface SimpleState<P extends Params = Params> {
|
|
|
47
47
|
type TransitionPhase = "deactivating" | "activating";
|
|
48
48
|
type TransitionReason = "success" | "blocked" | "cancelled" | "error";
|
|
49
49
|
interface TransitionMeta {
|
|
50
|
-
readonly reload?: boolean;
|
|
51
|
-
readonly redirected?: boolean;
|
|
52
50
|
phase: TransitionPhase;
|
|
53
|
-
from?: string;
|
|
54
51
|
reason: TransitionReason;
|
|
52
|
+
reload?: boolean;
|
|
53
|
+
redirected?: boolean;
|
|
54
|
+
from?: string;
|
|
55
55
|
blocker?: string;
|
|
56
56
|
segments: {
|
|
57
57
|
deactivated: string[];
|
|
@@ -494,6 +494,7 @@ interface Router<D extends DefaultDependencies = DefaultDependencies> {
|
|
|
494
494
|
subscribe: (listener: SubscribeFn) => Unsubscribe;
|
|
495
495
|
navigate: (routeName: string, routeParams?: Params, options?: NavigationOptions) => Promise<State>;
|
|
496
496
|
navigateToDefault: (options?: NavigationOptions) => Promise<State>;
|
|
497
|
+
navigateToNotFound: (path?: string) => State;
|
|
497
498
|
}
|
|
498
499
|
/**
|
|
499
500
|
* Factory function for creating plugins.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"inputs":{"../../node_modules/.pnpm/tsup@8.5.1_jiti@2.6.1_postcss@8.5.
|
|
1
|
+
{"inputs":{"../../node_modules/.pnpm/tsup@8.5.1_jiti@2.6.1_postcss@8.5.8_typescript@5.9.3_yaml@2.8.2/node_modules/tsup/assets/cjs_shims.js":{"bytes":569,"imports":[],"format":"esm"},"src/index.ts":{"bytes":1392,"imports":[{"path":"/home/runner/work/real-router/real-router/node_modules/.pnpm/tsup@8.5.1_jiti@2.6.1_postcss@8.5.8_typescript@5.9.3_yaml@2.8.2/node_modules/tsup/assets/cjs_shims.js","kind":"import-statement","external":true}],"format":"esm"}},"outputs":{"dist/cjs/index.js":{"imports":[],"exports":[],"entryPoint":"src/index.ts","inputs":{"src/index.ts":{"bytesInOutput":0}},"bytes":0}}}
|
package/dist/esm/index.d.mts
CHANGED
|
@@ -47,11 +47,11 @@ interface SimpleState<P extends Params = Params> {
|
|
|
47
47
|
type TransitionPhase = "deactivating" | "activating";
|
|
48
48
|
type TransitionReason = "success" | "blocked" | "cancelled" | "error";
|
|
49
49
|
interface TransitionMeta {
|
|
50
|
-
readonly reload?: boolean;
|
|
51
|
-
readonly redirected?: boolean;
|
|
52
50
|
phase: TransitionPhase;
|
|
53
|
-
from?: string;
|
|
54
51
|
reason: TransitionReason;
|
|
52
|
+
reload?: boolean;
|
|
53
|
+
redirected?: boolean;
|
|
54
|
+
from?: string;
|
|
55
55
|
blocker?: string;
|
|
56
56
|
segments: {
|
|
57
57
|
deactivated: string[];
|
|
@@ -494,6 +494,7 @@ interface Router<D extends DefaultDependencies = DefaultDependencies> {
|
|
|
494
494
|
subscribe: (listener: SubscribeFn) => Unsubscribe;
|
|
495
495
|
navigate: (routeName: string, routeParams?: Params, options?: NavigationOptions) => Promise<State>;
|
|
496
496
|
navigateToDefault: (options?: NavigationOptions) => Promise<State>;
|
|
497
|
+
navigateToNotFound: (path?: string) => State;
|
|
497
498
|
}
|
|
498
499
|
/**
|
|
499
500
|
* Factory function for creating plugins.
|
package/package.json
CHANGED
package/src/base.ts
CHANGED
|
@@ -16,11 +16,11 @@ export type TransitionPhase = "deactivating" | "activating";
|
|
|
16
16
|
export type TransitionReason = "success" | "blocked" | "cancelled" | "error";
|
|
17
17
|
|
|
18
18
|
export interface TransitionMeta {
|
|
19
|
-
readonly reload?: boolean;
|
|
20
|
-
readonly redirected?: boolean;
|
|
21
19
|
phase: TransitionPhase;
|
|
22
|
-
from?: string;
|
|
23
20
|
reason: TransitionReason;
|
|
21
|
+
reload?: boolean;
|
|
22
|
+
redirected?: boolean;
|
|
23
|
+
from?: string;
|
|
24
24
|
blocker?: string;
|
|
25
25
|
segments: {
|
|
26
26
|
deactivated: string[];
|
package/src/router.ts
CHANGED
|
@@ -290,6 +290,8 @@ export interface Router<D extends DefaultDependencies = DefaultDependencies> {
|
|
|
290
290
|
) => Promise<State>;
|
|
291
291
|
|
|
292
292
|
navigateToDefault: (options?: NavigationOptions) => Promise<State>;
|
|
293
|
+
|
|
294
|
+
navigateToNotFound: (path?: string) => State;
|
|
293
295
|
}
|
|
294
296
|
|
|
295
297
|
// =============================================================================
|