兰宝车间质量管理系统-前端
src/types/router.d.ts
@@ -1,35 +1,34 @@
import { RouteRecordRaw } from 'vue-router';
import { LocationQuery, type RouteMeta as VRouteMeta } from 'vue-router';
declare module 'vue-router' {
   type RouteOption = {
      hidden?: boolean;
      permissions?: string[];
      roles?: string[];
      component?: any;
      children?: RouteOption[];
      alwaysShow?: boolean;
      parentPath?: string;
      meta?: {
         title: string;
         icon: string;
      };
   } & RouteRecordRaw;
  interface RouteMeta extends VRouteMeta {
    link?: string;
    title?: string;
    affix?: boolean;
    noCache?: boolean;
    activeMenu?: string;
    icon?: string;
    breadcrumb?: boolean;
  }
   interface _RouteLocationBase {
      children?: RouteOption[];
   }
  interface _RouteRecordBase {
    hidden?: boolean | string | number;
    permissions?: string[];
    roles?: string[];
    alwaysShow?: boolean;
    query?: string;
  }
   interface RouteLocationOptions {
      fullPath?: string;
   }
  interface _RouteLocationBase {
    children?: _RouteRecordBase[];
    path?: string;
  }
   interface TagView extends Partial<_RouteLocationBase> {
      title?: string;
      meta?: {
         link?: string;
         title?: string;
         affix?: boolean;
         noCache?: boolean;
      };
   }
  interface TagView {
    fullPath?: string;
    name?: string;
    path?: string;
    title?: string;
    meta?: RouteMeta;
    query?: LocationQuery;
  }
}