sv-router 0.8.0 → 0.8.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/package.json
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
<script>
|
|
2
|
-
import { params } from './create-router.svelte.js';
|
|
3
2
|
import RecursiveComponentTree from './RecursiveComponentTree.svelte';
|
|
4
3
|
|
|
5
4
|
/** @type {{ tree: import('svelte').Component[] }} */
|
|
@@ -9,10 +8,8 @@
|
|
|
9
8
|
const restTree = $derived(tree.slice(1));
|
|
10
9
|
</script>
|
|
11
10
|
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
{
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
</FirstComponent>
|
|
18
|
-
{/key}
|
|
11
|
+
<FirstComponent>
|
|
12
|
+
{#if restTree.length > 0}
|
|
13
|
+
<RecursiveComponentTree tree={restTree}></RecursiveComponentTree>
|
|
14
|
+
{/if}
|
|
15
|
+
</FirstComponent>
|
|
@@ -22,11 +22,11 @@ export const base = {
|
|
|
22
22
|
/** @type {{ value: import('svelte').Component[] }} */
|
|
23
23
|
export let componentTree = $state({ value: [] });
|
|
24
24
|
|
|
25
|
-
/** @type {{ value: Record<string, string> }} */
|
|
26
|
-
export let params = $state({ value: {} });
|
|
27
|
-
|
|
28
25
|
export let location = $state(updatedLocation());
|
|
29
26
|
|
|
27
|
+
/** @type {{ value: Record<string, string> }} */
|
|
28
|
+
let params = $state({ value: {} });
|
|
29
|
+
|
|
30
30
|
let meta = $state({ value: {} });
|
|
31
31
|
|
|
32
32
|
let navigationIndex = 0;
|