@solidjs/router 0.10.0-beta.3 → 0.10.0-beta.5
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 +18 -6
- package/dist/components.d.ts +2 -23
- package/dist/components.jsx +4 -81
- package/dist/data/action.d.ts +1 -0
- package/dist/data/action.js +7 -21
- package/dist/data/cache.js +8 -7
- package/dist/data/events.d.ts +2 -0
- package/dist/data/events.js +116 -0
- package/dist/index.d.ts +2 -2
- package/dist/index.js +455 -463
- package/dist/index.jsx +1 -1
- package/dist/routers/HashRouter.d.ts +4 -0
- package/dist/routers/HashRouter.js +36 -0
- package/dist/routers/MemoryRouter.d.ts +3 -0
- package/dist/routers/MemoryRouter.js +37 -0
- package/dist/routers/Router.d.ts +5 -0
- package/dist/routers/Router.js +28 -0
- package/dist/routers/StaticRouter.d.ts +5 -0
- package/dist/routers/StaticRouter.js +15 -0
- package/dist/routers/components.d.ts +17 -0
- package/dist/routers/components.jsx +70 -0
- package/dist/routers/createIntegration.d.ts +4 -0
- package/dist/routers/createIntegration.js +49 -0
- package/dist/routers/createIntegration.jsx +48 -0
- package/dist/routers/createRouter.d.ts +10 -0
- package/dist/routers/createRouter.js +49 -0
- package/dist/routers/index.d.ts +7 -0
- package/dist/routers/index.js +6 -0
- package/dist/routing.d.ts +5 -3
- package/dist/routing.js +61 -169
- package/dist/types.d.ts +8 -3
- package/package.json +1 -1
- package/dist/integration.d.ts +0 -15
- package/dist/integration.js +0 -154
package/README.md
CHANGED
|
@@ -456,12 +456,12 @@ function loadUser({params, location}) {
|
|
|
456
456
|
<Route path="/users/:id" component={User} load={loadUser} />;
|
|
457
457
|
```
|
|
458
458
|
|
|
459
|
-
The load function is called when the Route is loaded or eagerly when links are hovered. Inside your page component you
|
|
459
|
+
The load function is called when the Route is loaded or eagerly when links are hovered. Inside your page component you:
|
|
460
460
|
|
|
461
461
|
```jsx
|
|
462
462
|
// pages/users/[id].js
|
|
463
463
|
import { getUser } from ... // the cache function
|
|
464
|
-
|
|
464
|
+
|
|
465
465
|
export default function User(props) {
|
|
466
466
|
const user = createAsync(() => getUser(props.params.id));
|
|
467
467
|
return <h1>{user().name}</h1>;
|
|
@@ -542,9 +542,9 @@ render(() =>
|
|
|
542
542
|
By default, Solid Router uses `location.pathname` as route path. You can simply switch to hash mode through the `source` property on `<Router>` component.
|
|
543
543
|
|
|
544
544
|
```jsx
|
|
545
|
-
import {
|
|
545
|
+
import { HashRouter } from "@solidjs/router";
|
|
546
546
|
|
|
547
|
-
<
|
|
547
|
+
<HashRouter />;
|
|
548
548
|
```
|
|
549
549
|
|
|
550
550
|
### Memory Mode Router
|
|
@@ -552,11 +552,23 @@ import { Router, hashIntegration } from "@solidjs/router";
|
|
|
552
552
|
You can also use memory mode router for testing purpose.
|
|
553
553
|
|
|
554
554
|
```jsx
|
|
555
|
-
import {
|
|
555
|
+
import { MemoryRouter } from "@solidjs/router";
|
|
556
556
|
|
|
557
|
-
<
|
|
557
|
+
<MemoryRouter />;
|
|
558
558
|
```
|
|
559
559
|
|
|
560
|
+
### SSR Routing
|
|
561
|
+
|
|
562
|
+
For SSR you can use the static router directly or the browser Router defaults to it on the server, just pass in the url.
|
|
563
|
+
|
|
564
|
+
```jsx
|
|
565
|
+
import { isServer } from "solid-js/web";
|
|
566
|
+
import { Router } from "@solidjs/router";
|
|
567
|
+
|
|
568
|
+
<Router url={isServer ? req.url : ""} />;
|
|
569
|
+
```
|
|
570
|
+
|
|
571
|
+
|
|
560
572
|
## Components
|
|
561
573
|
|
|
562
574
|
### `<A>`
|
package/dist/components.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
import type { Location,
|
|
1
|
+
import type { JSX } from "solid-js";
|
|
2
|
+
import type { Location, Navigator } from "./types";
|
|
3
3
|
declare module "solid-js" {
|
|
4
4
|
namespace JSX {
|
|
5
5
|
interface AnchorHTMLAttributes<T> {
|
|
@@ -10,26 +10,6 @@ declare module "solid-js" {
|
|
|
10
10
|
}
|
|
11
11
|
}
|
|
12
12
|
}
|
|
13
|
-
export type RouterProps = {
|
|
14
|
-
base?: string;
|
|
15
|
-
root?: Component<RouteSectionProps>;
|
|
16
|
-
children: JSX.Element;
|
|
17
|
-
} & ({
|
|
18
|
-
url?: never;
|
|
19
|
-
source?: RouterIntegration | LocationChangeSignal;
|
|
20
|
-
} | {
|
|
21
|
-
source?: never;
|
|
22
|
-
url: string;
|
|
23
|
-
});
|
|
24
|
-
export declare const Router: (props: RouterProps) => JSX.Element;
|
|
25
|
-
export type RouteProps<S extends string> = {
|
|
26
|
-
path?: S | S[];
|
|
27
|
-
children?: JSX.Element;
|
|
28
|
-
load?: RouteLoadFunc;
|
|
29
|
-
matchFilters?: MatchFilters<S>;
|
|
30
|
-
component?: Component;
|
|
31
|
-
};
|
|
32
|
-
export declare const Route: <S extends string>(props: RouteProps<S>) => JSX.Element;
|
|
33
13
|
export interface AnchorProps extends Omit<JSX.AnchorHTMLAttributes<HTMLAnchorElement>, "state"> {
|
|
34
14
|
href: string;
|
|
35
15
|
replace?: boolean | undefined;
|
|
@@ -40,7 +20,6 @@ export interface AnchorProps extends Omit<JSX.AnchorHTMLAttributes<HTMLAnchorEle
|
|
|
40
20
|
end?: boolean | undefined;
|
|
41
21
|
}
|
|
42
22
|
export declare function A(props: AnchorProps): JSX.Element;
|
|
43
|
-
export { A as Link, A as NavLink, AnchorProps as LinkProps, AnchorProps as NavLinkProps };
|
|
44
23
|
export interface NavigateProps {
|
|
45
24
|
href: ((args: {
|
|
46
25
|
navigate: Navigator;
|
package/dist/components.jsx
CHANGED
|
@@ -1,83 +1,8 @@
|
|
|
1
1
|
/*@refresh skip*/
|
|
2
|
-
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import { normalizePath, createMemoObject } from "./utils";
|
|
7
|
-
export const Router = (props) => {
|
|
8
|
-
let e;
|
|
9
|
-
const { source, url, base } = props;
|
|
10
|
-
const integration = source ||
|
|
11
|
-
(isServer
|
|
12
|
-
? staticIntegration({ value: url || ((e = getRequestEvent()) && getPath(e.request.url)) || "" })
|
|
13
|
-
: pathIntegration());
|
|
14
|
-
const routeDefs = children(() => props.children);
|
|
15
|
-
const branches = createMemo(() => createBranches(props.root ? { component: props.root, children: routeDefs() } : routeDefs(), props.base || ""));
|
|
16
|
-
const routerState = createRouterContext(integration, branches, base);
|
|
17
|
-
return (<RouterContextObj.Provider value={routerState}>
|
|
18
|
-
<Routes routerState={routerState} branches={branches()}/>
|
|
19
|
-
</RouterContextObj.Provider>);
|
|
20
|
-
};
|
|
21
|
-
function getPath(url) {
|
|
22
|
-
const u = new URL(url);
|
|
23
|
-
return u.pathname + u.search;
|
|
24
|
-
}
|
|
25
|
-
function Routes(props) {
|
|
26
|
-
const matches = createMemo(() => getRouteMatches(props.branches, props.routerState.location.pathname));
|
|
27
|
-
const params = createMemoObject(() => {
|
|
28
|
-
const m = matches();
|
|
29
|
-
const params = {};
|
|
30
|
-
for (let i = 0; i < m.length; i++) {
|
|
31
|
-
Object.assign(params, m[i].params);
|
|
32
|
-
}
|
|
33
|
-
return params;
|
|
34
|
-
});
|
|
35
|
-
const disposers = [];
|
|
36
|
-
let root;
|
|
37
|
-
const routeStates = createMemo(on(matches, (nextMatches, prevMatches, prev) => {
|
|
38
|
-
let equal = prevMatches && nextMatches.length === prevMatches.length;
|
|
39
|
-
const next = [];
|
|
40
|
-
for (let i = 0, len = nextMatches.length; i < len; i++) {
|
|
41
|
-
const prevMatch = prevMatches && prevMatches[i];
|
|
42
|
-
const nextMatch = nextMatches[i];
|
|
43
|
-
if (prev && prevMatch && nextMatch.route.key === prevMatch.route.key) {
|
|
44
|
-
next[i] = prev[i];
|
|
45
|
-
}
|
|
46
|
-
else {
|
|
47
|
-
equal = false;
|
|
48
|
-
if (disposers[i]) {
|
|
49
|
-
disposers[i]();
|
|
50
|
-
}
|
|
51
|
-
createRoot(dispose => {
|
|
52
|
-
disposers[i] = dispose;
|
|
53
|
-
next[i] = createRouteContext(props.routerState, next[i - 1] || props.routerState.base, createOutlet(() => routeStates()[i + 1]), () => matches()[i], params);
|
|
54
|
-
});
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
disposers.splice(nextMatches.length).forEach(dispose => dispose());
|
|
58
|
-
if (prev && equal) {
|
|
59
|
-
return prev;
|
|
60
|
-
}
|
|
61
|
-
root = next[0];
|
|
62
|
-
return next;
|
|
63
|
-
}));
|
|
64
|
-
return (<Show when={routeStates() && root} keyed>
|
|
65
|
-
{route => <RouteContextObj.Provider value={route}>{route.outlet()}</RouteContextObj.Provider>}
|
|
66
|
-
</Show>);
|
|
67
|
-
}
|
|
68
|
-
const createOutlet = (child) => {
|
|
69
|
-
return () => (<Show when={child()} keyed>
|
|
70
|
-
{child => <RouteContextObj.Provider value={child}>{child.outlet()}</RouteContextObj.Provider>}
|
|
71
|
-
</Show>);
|
|
72
|
-
};
|
|
73
|
-
export const Route = (props) => {
|
|
74
|
-
const childRoutes = children(() => props.children);
|
|
75
|
-
return mergeProps(props, {
|
|
76
|
-
get children() {
|
|
77
|
-
return childRoutes();
|
|
78
|
-
}
|
|
79
|
-
});
|
|
80
|
-
};
|
|
2
|
+
"use client";
|
|
3
|
+
import { createMemo, mergeProps, splitProps } from "solid-js";
|
|
4
|
+
import { useHref, useLocation, useNavigate, useResolvedPath } from "./routing";
|
|
5
|
+
import { normalizePath } from "./utils";
|
|
81
6
|
export function A(props) {
|
|
82
7
|
props = mergeProps({ inactiveClass: "inactive", activeClass: "active" }, props);
|
|
83
8
|
const [, rest] = splitProps(props, [
|
|
@@ -106,8 +31,6 @@ export function A(props) {
|
|
|
106
31
|
...rest.classList
|
|
107
32
|
}} aria-current={isActive() ? "page" : undefined}/>);
|
|
108
33
|
}
|
|
109
|
-
// deprecated alias exports
|
|
110
|
-
export { A as Link, A as NavLink };
|
|
111
34
|
export function Navigate(props) {
|
|
112
35
|
const navigate = useNavigate();
|
|
113
36
|
const location = useLocation();
|
package/dist/data/action.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { JSX } from "solid-js";
|
|
2
2
|
import { Submission } from "../types";
|
|
3
3
|
export type Action<T, U> = ((vars: T) => Promise<U>) & JSX.SerializableAttributeValue;
|
|
4
|
+
export declare const actions: Map<string, Function>;
|
|
4
5
|
export declare function useSubmissions<T, U>(fn: Action<T, U>, filter?: (arg: T) => boolean): Submission<T, U>[] & {
|
|
5
6
|
pending: boolean;
|
|
6
7
|
};
|
package/dist/data/action.js
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { $TRACK, createMemo, createSignal } from "solid-js";
|
|
2
2
|
import { isServer } from "solid-js/web";
|
|
3
|
-
import {
|
|
3
|
+
import { useRouter } from "../routing";
|
|
4
4
|
import { redirectStatusCodes } from "../utils";
|
|
5
5
|
import { revalidate } from "./cache";
|
|
6
|
+
export const actions = /* #__PURE__ */ new Map();
|
|
6
7
|
export function useSubmissions(fn, filter) {
|
|
7
8
|
const router = useRouter();
|
|
8
9
|
const subs = createMemo(() => router.submissions[0]().filter(s => s.url === fn.toString() && (!filter || filter(s.input))));
|
|
@@ -18,26 +19,11 @@ export function useSubmissions(fn, filter) {
|
|
|
18
19
|
}
|
|
19
20
|
export function useSubmission(fn, filter) {
|
|
20
21
|
const submissions = useSubmissions(fn, filter);
|
|
21
|
-
return {
|
|
22
|
-
get
|
|
23
|
-
return submissions[
|
|
24
|
-
},
|
|
25
|
-
get retry() {
|
|
26
|
-
return submissions[0]?.retry;
|
|
27
|
-
},
|
|
28
|
-
get url() {
|
|
29
|
-
return submissions[0]?.url;
|
|
30
|
-
},
|
|
31
|
-
get input() {
|
|
32
|
-
return submissions[0]?.input;
|
|
33
|
-
},
|
|
34
|
-
get result() {
|
|
35
|
-
return submissions[0]?.result;
|
|
36
|
-
},
|
|
37
|
-
get pending() {
|
|
38
|
-
return submissions[0]?.pending;
|
|
22
|
+
return new Proxy({}, {
|
|
23
|
+
get(_, property) {
|
|
24
|
+
return submissions[submissions.length - 1]?.[property];
|
|
39
25
|
}
|
|
40
|
-
};
|
|
26
|
+
});
|
|
41
27
|
}
|
|
42
28
|
export function useAction(action) {
|
|
43
29
|
const router = useRouter();
|
|
@@ -86,7 +72,7 @@ export function action(fn, name) {
|
|
|
86
72
|
return url;
|
|
87
73
|
};
|
|
88
74
|
if (!isServer)
|
|
89
|
-
|
|
75
|
+
actions.set(url, mutate);
|
|
90
76
|
return mutate;
|
|
91
77
|
}
|
|
92
78
|
async function handleResponse(response, navigate) {
|
package/dist/data/cache.js
CHANGED
|
@@ -51,13 +51,14 @@ export function cache(fn, name, options) {
|
|
|
51
51
|
if (cached[2] === "preload" && intent !== "preload") {
|
|
52
52
|
cached[0] = now;
|
|
53
53
|
}
|
|
54
|
+
let res = cached[1];
|
|
54
55
|
if (!isServer && intent === "navigate") {
|
|
55
|
-
"then" in cached[1]
|
|
56
|
+
res = "then" in cached[1]
|
|
56
57
|
? cached[1].then(handleResponse(false), handleResponse(true))
|
|
57
58
|
: handleResponse(false)(cached[1]);
|
|
58
59
|
startTransition(() => revalidateSignals(cached[3], cached[0])); // update version
|
|
59
60
|
}
|
|
60
|
-
return
|
|
61
|
+
return res;
|
|
61
62
|
}
|
|
62
63
|
let res = !isServer && sharedConfig.context && sharedConfig.load
|
|
63
64
|
? sharedConfig.load(key) // hydrating
|
|
@@ -66,11 +67,6 @@ export function cache(fn, name, options) {
|
|
|
66
67
|
if (isServer && sharedConfig.context && !sharedConfig.context.noHydrate) {
|
|
67
68
|
sharedConfig.context && sharedConfig.context.serialize(key, res);
|
|
68
69
|
}
|
|
69
|
-
if (intent !== "preload") {
|
|
70
|
-
"then" in res
|
|
71
|
-
? res.then(handleResponse(false), handleResponse(true))
|
|
72
|
-
: handleResponse(false)(res);
|
|
73
|
-
}
|
|
74
70
|
if (cached) {
|
|
75
71
|
cached[0] = now;
|
|
76
72
|
cached[1] = res;
|
|
@@ -82,6 +78,11 @@ export function cache(fn, name, options) {
|
|
|
82
78
|
}
|
|
83
79
|
else
|
|
84
80
|
cache.set(key, (cached = [now, res, intent, new Set(version ? [version] : [])]));
|
|
81
|
+
if (intent !== "preload") {
|
|
82
|
+
res = "then" in res
|
|
83
|
+
? res.then(handleResponse(false), handleResponse(true))
|
|
84
|
+
: handleResponse(false)(res);
|
|
85
|
+
}
|
|
85
86
|
return res;
|
|
86
87
|
function handleResponse(error) {
|
|
87
88
|
return (v) => {
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
import { delegateEvents } from "solid-js/web";
|
|
2
|
+
import { onCleanup } from "solid-js";
|
|
3
|
+
import { actions } from "./action";
|
|
4
|
+
export function setupNativeEvents(router) {
|
|
5
|
+
const basePath = router.base.path();
|
|
6
|
+
const navigateFromRoute = router.navigatorFactory(router.base);
|
|
7
|
+
let preloadTimeout = {};
|
|
8
|
+
function isSvg(el) {
|
|
9
|
+
return el.namespaceURI === "http://www.w3.org/2000/svg";
|
|
10
|
+
}
|
|
11
|
+
function handleAnchor(evt) {
|
|
12
|
+
if (evt.defaultPrevented ||
|
|
13
|
+
evt.button !== 0 ||
|
|
14
|
+
evt.metaKey ||
|
|
15
|
+
evt.altKey ||
|
|
16
|
+
evt.ctrlKey ||
|
|
17
|
+
evt.shiftKey)
|
|
18
|
+
return;
|
|
19
|
+
const a = evt
|
|
20
|
+
.composedPath()
|
|
21
|
+
.find(el => el instanceof Node && el.nodeName.toUpperCase() === "A");
|
|
22
|
+
if (!a)
|
|
23
|
+
return;
|
|
24
|
+
const svg = isSvg(a);
|
|
25
|
+
const href = svg ? a.href.baseVal : a.href;
|
|
26
|
+
const target = svg ? a.target.baseVal : a.target;
|
|
27
|
+
if (target || (!href && !a.hasAttribute("state")))
|
|
28
|
+
return;
|
|
29
|
+
const rel = (a.getAttribute("rel") || "").split(/\s+/);
|
|
30
|
+
if (a.hasAttribute("download") || (rel && rel.includes("external")))
|
|
31
|
+
return;
|
|
32
|
+
const url = svg ? new URL(href, document.baseURI) : new URL(href);
|
|
33
|
+
if (url.origin !== window.location.origin ||
|
|
34
|
+
(basePath && url.pathname && !url.pathname.toLowerCase().startsWith(basePath.toLowerCase())))
|
|
35
|
+
return;
|
|
36
|
+
return [a, url];
|
|
37
|
+
}
|
|
38
|
+
function handleAnchorClick(evt) {
|
|
39
|
+
const res = handleAnchor(evt);
|
|
40
|
+
if (!res)
|
|
41
|
+
return;
|
|
42
|
+
const [a, url] = res;
|
|
43
|
+
const to = router.parsePath(url.pathname + url.search + url.hash);
|
|
44
|
+
const state = a.getAttribute("state");
|
|
45
|
+
evt.preventDefault();
|
|
46
|
+
navigateFromRoute(to, {
|
|
47
|
+
resolve: false,
|
|
48
|
+
replace: a.hasAttribute("replace"),
|
|
49
|
+
scroll: !a.hasAttribute("noscroll"),
|
|
50
|
+
state: state && JSON.parse(state)
|
|
51
|
+
});
|
|
52
|
+
}
|
|
53
|
+
function handleAnchorPreload(evt) {
|
|
54
|
+
const res = handleAnchor(evt);
|
|
55
|
+
if (!res)
|
|
56
|
+
return;
|
|
57
|
+
const [a, url] = res;
|
|
58
|
+
if (!preloadTimeout[url.pathname])
|
|
59
|
+
router.preloadRoute(url, a.getAttribute("preload") !== "false");
|
|
60
|
+
}
|
|
61
|
+
function handleAnchorIn(evt) {
|
|
62
|
+
const res = handleAnchor(evt);
|
|
63
|
+
if (!res)
|
|
64
|
+
return;
|
|
65
|
+
const [a, url] = res;
|
|
66
|
+
if (preloadTimeout[url.pathname])
|
|
67
|
+
return;
|
|
68
|
+
preloadTimeout[url.pathname] = setTimeout(() => {
|
|
69
|
+
router.preloadRoute(url, a.getAttribute("preload") !== "false");
|
|
70
|
+
delete preloadTimeout[url.pathname];
|
|
71
|
+
}, 200);
|
|
72
|
+
}
|
|
73
|
+
function handleAnchorOut(evt) {
|
|
74
|
+
const res = handleAnchor(evt);
|
|
75
|
+
if (!res)
|
|
76
|
+
return;
|
|
77
|
+
const [, url] = res;
|
|
78
|
+
if (preloadTimeout[url.pathname]) {
|
|
79
|
+
clearTimeout(preloadTimeout[url.pathname]);
|
|
80
|
+
delete preloadTimeout[url.pathname];
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
function handleFormSubmit(evt) {
|
|
84
|
+
let actionRef = (evt.submitter && evt.submitter.getAttribute("formaction")) || evt.target.action;
|
|
85
|
+
if (!actionRef)
|
|
86
|
+
return;
|
|
87
|
+
if (!actionRef.startsWith("action:")) {
|
|
88
|
+
const url = new URL(actionRef);
|
|
89
|
+
actionRef = router.parsePath(url.pathname + url.search);
|
|
90
|
+
if (!actionRef.startsWith(router.actionBase))
|
|
91
|
+
return;
|
|
92
|
+
}
|
|
93
|
+
const handler = actions.get(actionRef);
|
|
94
|
+
if (handler) {
|
|
95
|
+
evt.preventDefault();
|
|
96
|
+
const data = new FormData(evt.target);
|
|
97
|
+
handler.call(router, data);
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
// ensure delegated event run first
|
|
101
|
+
delegateEvents(["click", "submit"]);
|
|
102
|
+
document.addEventListener("click", handleAnchorClick);
|
|
103
|
+
document.addEventListener("mouseover", handleAnchorIn);
|
|
104
|
+
document.addEventListener("mouseout", handleAnchorOut);
|
|
105
|
+
document.addEventListener("focusin", handleAnchorPreload);
|
|
106
|
+
document.addEventListener("touchstart", handleAnchorPreload);
|
|
107
|
+
document.addEventListener("submit", handleFormSubmit);
|
|
108
|
+
onCleanup(() => {
|
|
109
|
+
document.removeEventListener("click", handleAnchorClick);
|
|
110
|
+
document.removeEventListener("mouseover", handleAnchorIn);
|
|
111
|
+
document.removeEventListener("mouseout", handleAnchorOut);
|
|
112
|
+
document.removeEventListener("focusin", handleAnchorPreload);
|
|
113
|
+
document.removeEventListener("touchstart", handleAnchorPreload);
|
|
114
|
+
document.removeEventListener("submit", handleFormSubmit);
|
|
115
|
+
});
|
|
116
|
+
}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
+
export * from "./routers";
|
|
1
2
|
export * from "./components";
|
|
2
|
-
export * from "./integration";
|
|
3
3
|
export * from "./lifecycle";
|
|
4
4
|
export { useHref, useIsRouting, useLocation, useMatch, useNavigate, useParams, useResolvedPath, useSearchParams, useBeforeLeave, } from "./routing";
|
|
5
5
|
export { mergeSearchString as _mergeSearchString } from "./utils";
|
|
6
6
|
export * from "./data";
|
|
7
|
-
export type { Location, LocationChange,
|
|
7
|
+
export type { Location, LocationChange, NavigateOptions, Navigator, OutputMatch, Params, RouteSectionProps, RouteLoadFunc, RouteLoadFuncArgs, RouteDefinition, RouterIntegration, RouterOutput, RouterUtils, SetParams, BeforeLeaveEventArgs } from "./types";
|