chore: add some notes

This commit is contained in:
vben
2020-11-18 22:41:59 +08:00
parent 815250ed34
commit 46e0875374
87 changed files with 926 additions and 728 deletions

View File

@@ -4,34 +4,40 @@ import router, { setupRouter } from '/@/router';
import { setupStore } from '/@/store';
import { setupAntd } from '/@/setup/ant-design-vue';
import { setupErrorHandle } from '/@/setup/error-handle';
import { setupDirectives } from '/@/setup/directives';
import { setupGlobDirectives } from '/@/setup/directives';
import { isDevMode, isProdMode, isUseMock } from '/@/utils/env';
import { setupProdMockServer } from '../mock/_createProductionServer';
import { setApp } from './useApp';
import { setApp } from '/@/setup/Application';
import App from './App.vue';
import { isDevMode, isProdMode, isUseMock } from '/@/utils/env';
import '/@/design/index.less';
const app = createApp(App);
// ui
// Configure component library
setupAntd(app);
// router
// Configure routing
setupRouter(app);
// store
// Configure vuex store
setupStore(app);
// Directives
setupDirectives(app);
// Register global directive
setupGlobDirectives(app);
// error-handle
// Configure global error handling
setupErrorHandle(app);
// Mount when the route is ready
router.isReady().then(() => {
app.mount('#app');
});
// The development environment takes effect
if (isDevMode()) {
app.config.performance = true;
window.__APP__ = app;