随笔分类 - Vue3
摘要:1. 将scene定义成全局变量. app.config.globalProperties.$scene = '' //mainjs中定义 import { getCurrentInstance } from 'vue' const { proxy } = getCurrentInstance()
阅读全文
摘要:Vue3+Vite做动态路由的时候:之前的引入方式是: let obj = { path: v.path, name: v.name, icon: v.icon, component: import(`${v.component}`), children: setRouter(v.children)
阅读全文