xiaoxian521
3 years ago
12 changed files with 522 additions and 388 deletions
-
22package.json
-
781pnpm-lock.yaml
-
6src/layout/components/navbar.vue
-
12src/layout/components/sidebar/horizontal.vue
-
5src/layout/components/sidebar/mixNav.vue
-
2src/layout/components/sidebar/sidebarItem.vue
-
1src/layout/components/sidebar/vertical.vue
-
9src/layout/hooks/nav.ts
-
8src/mockProdServer.ts
-
7src/style/element-plus.scss
-
1src/style/sidebar.scss
-
56src/utils/tree.ts
781
pnpm-lock.yaml
File diff suppressed because it is too large
View File
File diff suppressed because it is too large
View File
@ -1,7 +1,11 @@ |
|||||
import { createProdMockServer } from "vite-plugin-mock/es/createProdMockServer"; |
import { createProdMockServer } from "vite-plugin-mock/es/createProdMockServer"; |
||||
import asyncRoutesMock from "../mock/asyncRoutes"; |
|
||||
|
|
||||
export const mockModules = [...asyncRoutesMock]; |
|
||||
|
const modules = import.meta.globEager("../mock/*.ts"); |
||||
|
const mockModules = []; |
||||
|
|
||||
|
Object.keys(modules).forEach(key => { |
||||
|
mockModules.push(...modules[key].default); |
||||
|
}); |
||||
|
|
||||
export function setupProdMockServer() { |
export function setupProdMockServer() { |
||||
createProdMockServer(mockModules); |
createProdMockServer(mockModules); |
||||
|
Write
Preview
Loading…
Cancel
Save
Reference in new issue