Skip to content

Commit

Permalink
chore: 更新依赖
Browse files Browse the repository at this point in the history
  • Loading branch information
fonghehe committed Apr 16, 2023
1 parent 04f7085 commit 5fc569c
Show file tree
Hide file tree
Showing 5 changed files with 487 additions and 459 deletions.
7 changes: 1 addition & 6 deletions build/vite/plugins/mock.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,7 @@ export const ConfigMockPlugin = (isBuild: boolean) => {
return viteMockServe({
ignore: /^\_/,
mockPath: 'mock',
localEnabled: !isBuild,
prodEnabled: false, //实际开发请关闭,会影响打包体积
enable: !isBuild,
// https://github.com/anncwb/vite-plugin-mock/issues/9
injectCode: `
import { setupProdMockServer } from '../mock/_createProdMockServer';
setupProdMockServer();
`,
});
};
2 changes: 1 addition & 1 deletion mock/_createProdMockServer.ts → mock/mockProdServer.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { createProdMockServer } from 'vite-plugin-mock/es/createProdMockServer';
import { createProdMockServer } from 'vite-plugin-mock/dist/client';
// 批量加载
const modules: Record<string, any> = import.meta.glob('./mock/*.ts', { eager: true });

Expand Down
10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -59,24 +59,24 @@
"mockjs": "^1.1.0",
"nprogress": "^0.2.0",
"plop": "^3.1.2",
"postcss": "^8.4.22",
"postcss": "^8.4.23",
"postcss-html": "^1.5.0",
"postcss-less": "^6.0.0",
"postcss-px-to-viewport": "^1.1.1",
"prettier": "^2.8.7",
"prettier": "^2.8.8",
"rollup-plugin-visualizer": "^5.9.0",
"stylelint": "^15.5.0",
"stylelint": "^15.6.1",
"stylelint-config-prettier": "^9.0.5",
"stylelint-config-recommended": "^12.0.0",
"stylelint-config-recommended-vue": "^1.4.0",
"stylelint-config-standard": "^33.0.0",
"stylelint-order": "^6.0.3",
"typescript": "4.9.5",
"typescript": "5.0.4",
"unocss": "^0.51.5",
"unplugin-auto-import": "^0.15.3",
"unplugin-icons": "^0.16.1",
"unplugin-vue-components": "^0.24.1",
"vite": "^4.3.0",
"vite": "^4.3.5",
"vite-plugin-compression": "^0.5.1",
"vite-plugin-html": "^3.2.0",
"vite-plugin-imagemin": "^0.6.1",
Expand Down
Loading

0 comments on commit 5fc569c

Please sign in to comment.