@argon-router/react 0.12.0 → 1.0.0-rc.0
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/LICENSE.MD +21 -0
- package/README.md +0 -3
- package/dist/index.cjs +1 -1
- package/dist/index.d.ts +10 -12
- package/dist/index.js +107 -149
- package/package.json +9 -8
package/LICENSE.MD
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2024 Edward Gigolaev
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
CHANGED
|
@@ -2,9 +2,6 @@
|
|
|
2
2
|
|
|
3
3
|
Router without a headache
|
|
4
4
|
|
|
5
|
-
> [!WARNING]
|
|
6
|
-
> argon-router is not production ready yet and still may have bugs and unstable API. If you found bug — please report it on GitHub.
|
|
7
|
-
|
|
8
5
|
## Documentation
|
|
9
6
|
|
|
10
7
|
For additional information, guides and api reference visit [documentation site](https://movpushmov.dev/argon-router/)
|
package/dist/index.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("react/jsx-runtime"),u=require("react"),h=require("effector-react"),w=require("@argon-router/core"),p=require("effector"),b=u.createContext(null),j=u.createContext(null),g=e=>o.jsx(b.Provider,{value:e.router,children:e.children});function x(){const e=u.useContext(b);if(!e)throw new Error("[useRouter] Router not found. Add RouterProvider in app root");return e}function k(){return h.useUnit(x())}function V(e,t){const{knownRoutes:n}=x(),r=n.find(({route:s})=>s===e),{onOpen:i}=h.useUnit(e);if(!r)throw console.error("[useLink route log]",e),new Error("[useLink] Route not found. Maybe it is not passed into createRouter?");return{path:r.build(t??void 0),onOpen:i}}const m=u.forwardRef((e,t)=>{const{to:n,params:r,onClick:i,replace:s,query:c,...a}=e,{path:f,onOpen:d}=V(n,r);return o.jsx("a",{...a,ref:t,href:f,onClick:l=>{i?.(l),!l.defaultPrevented&&(a.target&&a.target!=="_self"||l.metaKey||l.altKey||l.ctrlKey||l.shiftKey||(l.preventDefault(),d({params:r||{},replace:s,query:c})))}})});function L(e){const{layout:t,view:n,children:r}=e,i=t?()=>o.jsx(t,{children:o.jsx(n,{})}):()=>o.jsx(n,{});return{route:e.route,view:i,children:r}}function y(e,t){return t?t.getState(e):e.getState()}function O(e,t){return e.map(n=>w.is.router(n.route)?y(n.route.$activeRoutes,t).length>0:y(n.route.$isOpened,t))}function v(e){const t=h.useProvidedScope(),[n,r]=u.useState(O(e,t));return u.useEffect(()=>{const i=[];for(const[s,c]of e.entries())if(w.is.router(c.route)){const a=c.route,f=p.createWatch({unit:a.$activeRoutes,scope:t??void 0,fn:d=>{r(l=>{const R=[...l];return R[s]=d.length>0,R})}});i.push(f)}else i.push(p.createWatch({unit:c.route.$isOpened,scope:t??void 0,fn:a=>{r(f=>{const d=[...f];return d[s]=a,d})}}));return()=>{for(const s of i)s.unsubscribe()}},[e,t]),u.useMemo(()=>{const i=e.filter((s,c)=>n[c]);return i.reduce((s,c)=>s.filter(a=>a.route!==c.route.parent),i)},[e,n])}const C=e=>{const{routes:t,otherwise:n}=e;return()=>{const r=v(t).at(-1);return r?o.jsx(j.Provider,{value:{children:r.children??[]},children:u.createElement(r.view)}):n?o.jsx(n,{}):null}};function P(e){e.route.internal.setAsyncImport(e.view);const t=u.lazy(e.view),{layout:n,fallback:r=()=>o.jsx(o.Fragment,{})}=e,i=n?()=>o.jsx(n,{children:o.jsx(u.Suspense,{fallback:o.jsx(r,{}),children:o.jsx(t,{})})}):()=>o.jsx(u.Suspense,{fallback:o.jsx(r,{}),children:o.jsx(t,{})});return{route:e.route,view:i}}function S(e,t){const n=e;return t.map(({route:r,view:i})=>({route:r,view:()=>o.jsx(n,{children:u.createElement(i)})}))}const q=()=>{const{children:e}=u.useContext(j)??{children:[]},t=v(e).at(-1);return t?u.createElement(t.view):null};function E(e){return w.is.router(e)?h.useUnit(e.$activeRoutes).length>0:h.useUnit(e.$isOpened)}exports.Link=m;exports.Outlet=q;exports.RouterProvider=g;exports.createLazyRouteView=P;exports.createRouteView=L;exports.createRoutesView=C;exports.useIsOpened=E;exports.useLink=V;exports.useOpenedViews=v;exports.useRouter=k;exports.useRouterContext=x;exports.withLayout=S;
|
package/dist/index.d.ts
CHANGED
|
@@ -22,10 +22,8 @@ declare type BaseLinkProps<Params extends object | void = void> = {
|
|
|
22
22
|
|
|
23
23
|
declare interface CreateBaseRouteViewProps<T extends object | void = void> {
|
|
24
24
|
route: Route<T> | Router;
|
|
25
|
-
layout?:
|
|
26
|
-
|
|
27
|
-
}>;
|
|
28
|
-
children?: CreateBaseRouteViewProps<any>[];
|
|
25
|
+
layout?: LayoutComponent;
|
|
26
|
+
children?: RouteViewWithLayout[];
|
|
29
27
|
}
|
|
30
28
|
|
|
31
29
|
/**
|
|
@@ -122,6 +120,10 @@ declare type ForwardedLink = <Params extends object | void = void>(props: LinkPr
|
|
|
122
120
|
ref?: ForwardedRef<HTMLAnchorElement>;
|
|
123
121
|
}) => ReactNode;
|
|
124
122
|
|
|
123
|
+
declare type LayoutComponent = ComponentType<{
|
|
124
|
+
children: ReactNode;
|
|
125
|
+
}>;
|
|
126
|
+
|
|
125
127
|
/**
|
|
126
128
|
* @description Navigates user to provided route on click
|
|
127
129
|
* @link https://movpushmov.dev/argon-router/react/link.html
|
|
@@ -198,6 +200,10 @@ export declare interface RouteView {
|
|
|
198
200
|
children?: RouteView[];
|
|
199
201
|
}
|
|
200
202
|
|
|
203
|
+
declare type RouteViewWithLayout = RouteView & {
|
|
204
|
+
layout?: LayoutComponent;
|
|
205
|
+
};
|
|
206
|
+
|
|
201
207
|
export declare function useIsOpened(route: Route | Router): boolean;
|
|
202
208
|
|
|
203
209
|
export declare function useLink<T extends object | void = void>(to: Route<T>, params: T): {
|
|
@@ -258,11 +264,3 @@ export declare function withLayout(layout: ComponentType<{
|
|
|
258
264
|
}[];
|
|
259
265
|
|
|
260
266
|
export { }
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
declare module 'vitest' {
|
|
264
|
-
interface Assertion<T = any> extends CustomMatchers<T> {
|
|
265
|
-
}
|
|
266
|
-
interface AsymmetricMatchersContaining extends CustomMatchers {
|
|
267
|
-
}
|
|
268
|
-
}
|
package/dist/index.js
CHANGED
|
@@ -1,195 +1,153 @@
|
|
|
1
|
-
import { jsx, Fragment } from "react/jsx-runtime";
|
|
2
|
-
import { createContext, useContext, forwardRef, useState, useEffect, useMemo, createElement, lazy
|
|
3
|
-
import { useUnit, useProvidedScope } from "effector-react";
|
|
4
|
-
import { is } from "@argon-router/core";
|
|
5
|
-
import { createWatch } from "effector";
|
|
6
|
-
const
|
|
7
|
-
const OutletContext = createContext(
|
|
1
|
+
import { jsx as i, Fragment as L } from "react/jsx-runtime";
|
|
2
|
+
import { createContext as b, useContext as y, forwardRef as O, useState as P, useEffect as C, useMemo as S, createElement as h, lazy as $, Suspense as v } from "react";
|
|
3
|
+
import { useUnit as d, useProvidedScope as E } from "effector-react";
|
|
4
|
+
import { is as p } from "@argon-router/core";
|
|
5
|
+
import { createWatch as m } from "effector";
|
|
6
|
+
const V = b(null), g = b(
|
|
8
7
|
null
|
|
9
|
-
);
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
function useRouterContext() {
|
|
14
|
-
const context = useContext(RouterProviderContext);
|
|
15
|
-
if (!context) {
|
|
8
|
+
), j = (e) => /* @__PURE__ */ i(V.Provider, { value: e.router, children: e.children });
|
|
9
|
+
function k() {
|
|
10
|
+
const e = y(V);
|
|
11
|
+
if (!e)
|
|
16
12
|
throw new Error(
|
|
17
13
|
"[useRouter] Router not found. Add RouterProvider in app root"
|
|
18
14
|
);
|
|
19
|
-
|
|
20
|
-
return context;
|
|
15
|
+
return e;
|
|
21
16
|
}
|
|
22
|
-
function
|
|
23
|
-
return
|
|
17
|
+
function q() {
|
|
18
|
+
return d(k());
|
|
24
19
|
}
|
|
25
|
-
function
|
|
26
|
-
const { knownRoutes } =
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
)
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
throw new Error(
|
|
33
|
-
`[useLink] Route "${to}" not found. Maybe it is not passed into createRouter?`
|
|
20
|
+
function K(e, t) {
|
|
21
|
+
const { knownRoutes: n } = k(), r = n.find(
|
|
22
|
+
({ route: u }) => u === e
|
|
23
|
+
), { onOpen: o } = d(e);
|
|
24
|
+
if (!r)
|
|
25
|
+
throw console.error("[useLink route log]", e), new Error(
|
|
26
|
+
"[useLink] Route not found. Maybe it is not passed into createRouter?"
|
|
34
27
|
);
|
|
35
|
-
}
|
|
36
28
|
return {
|
|
37
|
-
path:
|
|
38
|
-
onOpen
|
|
29
|
+
path: r.build(t ?? void 0),
|
|
30
|
+
onOpen: o
|
|
39
31
|
};
|
|
40
32
|
}
|
|
41
|
-
const
|
|
42
|
-
const { to, params, onClick, replace, query, ...
|
|
43
|
-
|
|
44
|
-
return /* @__PURE__ */ jsx(
|
|
33
|
+
const D = O((e, t) => {
|
|
34
|
+
const { to: n, params: r, onClick: o, replace: u, query: s, ...c } = e, { path: f, onOpen: a } = K(n, r);
|
|
35
|
+
return /* @__PURE__ */ i(
|
|
45
36
|
"a",
|
|
46
37
|
{
|
|
47
|
-
...
|
|
48
|
-
ref,
|
|
49
|
-
href:
|
|
50
|
-
onClick: (
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
return;
|
|
57
|
-
}
|
|
58
|
-
if (e.metaKey || e.altKey || e.ctrlKey || e.shiftKey) {
|
|
59
|
-
return;
|
|
60
|
-
}
|
|
61
|
-
e.preventDefault();
|
|
62
|
-
onOpen({
|
|
63
|
-
params: params || {},
|
|
64
|
-
replace,
|
|
65
|
-
query
|
|
66
|
-
});
|
|
38
|
+
...c,
|
|
39
|
+
ref: t,
|
|
40
|
+
href: f,
|
|
41
|
+
onClick: (l) => {
|
|
42
|
+
o?.(l), !l.defaultPrevented && (c.target && c.target !== "_self" || l.metaKey || l.altKey || l.ctrlKey || l.shiftKey || (l.preventDefault(), a({
|
|
43
|
+
params: r || {},
|
|
44
|
+
replace: u,
|
|
45
|
+
query: s
|
|
46
|
+
})));
|
|
67
47
|
}
|
|
68
48
|
}
|
|
69
49
|
);
|
|
70
50
|
});
|
|
71
|
-
function
|
|
72
|
-
const { layout:
|
|
73
|
-
const view = Layout ? () => /* @__PURE__ */ jsx(Layout, { children: /* @__PURE__ */ jsx(View, {}) }) : () => /* @__PURE__ */ jsx(View, {});
|
|
51
|
+
function N(e) {
|
|
52
|
+
const { layout: t, view: n, children: r } = e, o = t ? () => /* @__PURE__ */ i(t, { children: /* @__PURE__ */ i(n, {}) }) : () => /* @__PURE__ */ i(n, {});
|
|
74
53
|
return {
|
|
75
|
-
route:
|
|
76
|
-
view
|
|
54
|
+
route: e.route,
|
|
55
|
+
view: o,
|
|
56
|
+
children: r
|
|
77
57
|
};
|
|
78
58
|
}
|
|
79
|
-
function
|
|
80
|
-
return
|
|
59
|
+
function R(e, t) {
|
|
60
|
+
return t ? t.getState(e) : e.getState();
|
|
81
61
|
}
|
|
82
|
-
function
|
|
83
|
-
return
|
|
84
|
-
if (is.router(view.route)) {
|
|
85
|
-
return getStoreValue(view.route.$activeRoutes, scope).length > 0;
|
|
86
|
-
}
|
|
87
|
-
return getStoreValue(view.route.$isOpened, scope);
|
|
88
|
-
});
|
|
62
|
+
function F(e, t) {
|
|
63
|
+
return e.map((n) => p.router(n.route) ? R(n.route.$activeRoutes, t).length > 0 : R(n.route.$isOpened, t));
|
|
89
64
|
}
|
|
90
|
-
function
|
|
91
|
-
const
|
|
92
|
-
|
|
93
|
-
getVisibilities(routes, scope)
|
|
65
|
+
function x(e) {
|
|
66
|
+
const t = E(), [n, r] = P(
|
|
67
|
+
F(e, t)
|
|
94
68
|
);
|
|
95
|
-
|
|
96
|
-
const
|
|
97
|
-
for (const [
|
|
98
|
-
if (
|
|
99
|
-
const
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
newVisibilities[index] = routes2.length > 0;
|
|
107
|
-
return newVisibilities;
|
|
69
|
+
return C(() => {
|
|
70
|
+
const o = [];
|
|
71
|
+
for (const [u, s] of e.entries())
|
|
72
|
+
if (p.router(s.route)) {
|
|
73
|
+
const c = s.route, f = m({
|
|
74
|
+
unit: c.$activeRoutes,
|
|
75
|
+
scope: t ?? void 0,
|
|
76
|
+
fn: (a) => {
|
|
77
|
+
r((l) => {
|
|
78
|
+
const w = [...l];
|
|
79
|
+
return w[u] = a.length > 0, w;
|
|
108
80
|
});
|
|
109
81
|
}
|
|
110
82
|
});
|
|
111
|
-
|
|
112
|
-
} else
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
unit:
|
|
116
|
-
scope:
|
|
117
|
-
fn: (
|
|
118
|
-
|
|
119
|
-
const
|
|
120
|
-
|
|
121
|
-
return newVisibilities;
|
|
83
|
+
o.push(f);
|
|
84
|
+
} else
|
|
85
|
+
o.push(
|
|
86
|
+
m({
|
|
87
|
+
unit: s.route.$isOpened,
|
|
88
|
+
scope: t ?? void 0,
|
|
89
|
+
fn: (c) => {
|
|
90
|
+
r((f) => {
|
|
91
|
+
const a = [...f];
|
|
92
|
+
return a[u] = c, a;
|
|
122
93
|
});
|
|
123
94
|
}
|
|
124
95
|
})
|
|
125
96
|
);
|
|
126
|
-
}
|
|
127
|
-
}
|
|
128
97
|
return () => {
|
|
129
|
-
for (const
|
|
130
|
-
|
|
131
|
-
}
|
|
98
|
+
for (const u of o)
|
|
99
|
+
u.unsubscribe();
|
|
132
100
|
};
|
|
133
|
-
}, [
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
(r) => r.route !== view.route.parent
|
|
101
|
+
}, [e, t]), S(() => {
|
|
102
|
+
const o = e.filter((u, s) => n[s]);
|
|
103
|
+
return o.reduce(
|
|
104
|
+
(u, s) => u.filter(
|
|
105
|
+
(c) => c.route !== s.route.parent
|
|
139
106
|
),
|
|
140
|
-
|
|
107
|
+
o
|
|
141
108
|
);
|
|
142
|
-
}, [
|
|
109
|
+
}, [e, n]);
|
|
143
110
|
}
|
|
144
|
-
const
|
|
145
|
-
const { routes, otherwise:
|
|
111
|
+
const U = (e) => {
|
|
112
|
+
const { routes: t, otherwise: n } = e;
|
|
146
113
|
return () => {
|
|
147
|
-
const
|
|
148
|
-
|
|
149
|
-
return NotFound ? /* @__PURE__ */ jsx(NotFound, {}) : null;
|
|
150
|
-
}
|
|
151
|
-
return /* @__PURE__ */ jsx(OutletContext.Provider, { value: { children: openedView.children ?? [] }, children: createElement(openedView.view) });
|
|
114
|
+
const r = x(t).at(-1);
|
|
115
|
+
return r ? /* @__PURE__ */ i(g.Provider, { value: { children: r.children ?? [] }, children: h(r.view) }) : n ? /* @__PURE__ */ i(n, {}) : null;
|
|
152
116
|
};
|
|
153
117
|
};
|
|
154
|
-
function
|
|
155
|
-
|
|
156
|
-
const
|
|
157
|
-
const { layout: Layout, fallback: Fallback = () => /* @__PURE__ */ jsx(Fragment, {}) } = props;
|
|
158
|
-
const view = Layout ? () => /* @__PURE__ */ jsx(Layout, { children: /* @__PURE__ */ jsx(Suspense, { fallback: /* @__PURE__ */ jsx(Fallback, {}), children: /* @__PURE__ */ jsx(View, {}) }) }) : () => /* @__PURE__ */ jsx(Suspense, { fallback: /* @__PURE__ */ jsx(Fallback, {}), children: /* @__PURE__ */ jsx(View, {}) });
|
|
118
|
+
function W(e) {
|
|
119
|
+
e.route.internal.setAsyncImport(e.view);
|
|
120
|
+
const t = $(e.view), { layout: n, fallback: r = () => /* @__PURE__ */ i(L, {}) } = e, o = n ? () => /* @__PURE__ */ i(n, { children: /* @__PURE__ */ i(v, { fallback: /* @__PURE__ */ i(r, {}), children: /* @__PURE__ */ i(t, {}) }) }) : () => /* @__PURE__ */ i(v, { fallback: /* @__PURE__ */ i(r, {}), children: /* @__PURE__ */ i(t, {}) });
|
|
159
121
|
return {
|
|
160
|
-
route:
|
|
161
|
-
view
|
|
122
|
+
route: e.route,
|
|
123
|
+
view: o
|
|
162
124
|
};
|
|
163
125
|
}
|
|
164
|
-
function
|
|
165
|
-
const
|
|
166
|
-
return
|
|
167
|
-
route,
|
|
168
|
-
view: () => /* @__PURE__ */
|
|
126
|
+
function B(e, t) {
|
|
127
|
+
const n = e;
|
|
128
|
+
return t.map(({ route: r, view: o }) => ({
|
|
129
|
+
route: r,
|
|
130
|
+
view: () => /* @__PURE__ */ i(n, { children: h(o) })
|
|
169
131
|
}));
|
|
170
132
|
}
|
|
171
|
-
const
|
|
172
|
-
const { children } =
|
|
173
|
-
|
|
174
|
-
if (!openedView) {
|
|
175
|
-
return null;
|
|
176
|
-
}
|
|
177
|
-
return createElement(openedView.view);
|
|
133
|
+
const G = () => {
|
|
134
|
+
const { children: e } = y(g) ?? { children: [] }, t = x(e).at(-1);
|
|
135
|
+
return t ? h(t.view) : null;
|
|
178
136
|
};
|
|
179
|
-
function
|
|
180
|
-
return
|
|
137
|
+
function H(e) {
|
|
138
|
+
return p.router(e) ? d(e.$activeRoutes).length > 0 : d(e.$isOpened);
|
|
181
139
|
}
|
|
182
140
|
export {
|
|
183
|
-
Link,
|
|
184
|
-
Outlet,
|
|
185
|
-
RouterProvider,
|
|
186
|
-
createLazyRouteView,
|
|
187
|
-
createRouteView,
|
|
188
|
-
createRoutesView,
|
|
189
|
-
useIsOpened,
|
|
190
|
-
useLink,
|
|
191
|
-
useOpenedViews,
|
|
192
|
-
useRouter,
|
|
193
|
-
useRouterContext,
|
|
194
|
-
withLayout
|
|
141
|
+
D as Link,
|
|
142
|
+
G as Outlet,
|
|
143
|
+
j as RouterProvider,
|
|
144
|
+
W as createLazyRouteView,
|
|
145
|
+
N as createRouteView,
|
|
146
|
+
U as createRoutesView,
|
|
147
|
+
H as useIsOpened,
|
|
148
|
+
K as useLink,
|
|
149
|
+
x as useOpenedViews,
|
|
150
|
+
q as useRouter,
|
|
151
|
+
k as useRouterContext,
|
|
152
|
+
B as withLayout
|
|
195
153
|
};
|
package/package.json
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
"registry": "https://registry.npmjs.org/"
|
|
6
6
|
},
|
|
7
7
|
"private": false,
|
|
8
|
-
"version": "0.
|
|
8
|
+
"version": "1.0.0-rc.0",
|
|
9
9
|
"description": "React bindings for argon router",
|
|
10
10
|
"keywords": [
|
|
11
11
|
"effector",
|
|
@@ -36,15 +36,11 @@
|
|
|
36
36
|
"type": "git",
|
|
37
37
|
"url": "git+https://github.com/movpushmov/argon-router.git"
|
|
38
38
|
},
|
|
39
|
-
"scripts": {
|
|
40
|
-
"build": "vite build",
|
|
41
|
-
"test": "vitest run"
|
|
42
|
-
},
|
|
43
39
|
"bugs": {
|
|
44
40
|
"url": "https://github.com/movpushmov/argon-router/issues"
|
|
45
41
|
},
|
|
46
42
|
"dependencies": {
|
|
47
|
-
"@argon-router/core": "
|
|
43
|
+
"@argon-router/core": "1.0.0-rc.0"
|
|
48
44
|
},
|
|
49
45
|
"devDependencies": {
|
|
50
46
|
"@babel/preset-react": "^7.26.3",
|
|
@@ -52,6 +48,7 @@
|
|
|
52
48
|
"@testing-library/react": "^16.2.0",
|
|
53
49
|
"@testing-library/user-event": "^14.6.1",
|
|
54
50
|
"@vitejs/plugin-react": "^4.3.4",
|
|
51
|
+
"happy-dom": "^20.8.3",
|
|
55
52
|
"jsdom": "^25.0.1"
|
|
56
53
|
},
|
|
57
54
|
"peerDependencies": {
|
|
@@ -59,5 +56,9 @@
|
|
|
59
56
|
"effector-react": ">=23",
|
|
60
57
|
"react": "18 || 19"
|
|
61
58
|
},
|
|
62
|
-
"gitHead": "9832d6cd282d6abd33c26ba4d03b9a1176110fc4"
|
|
63
|
-
|
|
59
|
+
"gitHead": "9832d6cd282d6abd33c26ba4d03b9a1176110fc4",
|
|
60
|
+
"scripts": {
|
|
61
|
+
"build": "vite build",
|
|
62
|
+
"test": "vitest run"
|
|
63
|
+
}
|
|
64
|
+
}
|