Add metadata timeout (#287)

* Add metadata timeout

* Fix lint
This commit is contained in:
DecDuck
2025-11-20 00:17:58 +00:00
committed by GitHub
parent 8f41024be2
commit beb824c8d9
9 changed files with 2790 additions and 784 deletions
+1 -2
View File
@@ -1,4 +1,3 @@
import type { RouteLocationNormalized } from "vue-router";
import type { NavigationItem } from "./types";
export const useCurrentNavigationIndex = (
@@ -9,7 +8,7 @@ export const useCurrentNavigationIndex = (
const currentNavigation = ref(-1);
function calculateCurrentNavIndex(to: RouteLocationNormalized) {
function calculateCurrentNavIndex(to: typeof route) {
const validOptions = navigation
.map((e, i) => ({ ...e, index: i }))
.filter((e) => to.fullPath.startsWith(e.prefix));