- {{initialState.userName}}
+ {{initialState.userName}}
+
diff --git a/packages/fes-preset-built-in/package.json b/packages/fes-preset-built-in/package.json
index 47714165..4f174ca5 100644
--- a/packages/fes-preset-built-in/package.json
+++ b/packages/fes-preset-built-in/package.json
@@ -1,6 +1,6 @@
{
"name": "@fesjs/preset-built-in",
- "version": "2.0.0",
+ "version": "2.0.1",
"description": "@fesjs/preset-built-in",
"main": "lib/index.js",
"types": "lib/index.d.ts",
diff --git a/packages/fes-preset-built-in/src/plugins/misc/route/template/routes.tpl b/packages/fes-preset-built-in/src/plugins/misc/route/template/routes.tpl
index 1d89a137..e6a6c6aa 100644
--- a/packages/fes-preset-built-in/src/plugins/misc/route/template/routes.tpl
+++ b/packages/fes-preset-built-in/src/plugins/misc/route/template/routes.tpl
@@ -3,13 +3,6 @@ import { plugin } from '@@/core/coreExports';
export function getRoutes() {
const routes = {{{ routes }}};
-
- plugin.applyPlugins({
- key: 'patchRoutes',
- type: ApplyPluginsType.event,
- args: { routes },
- });
-
return routes;
}
@@ -28,7 +21,13 @@ export const createRouter = (routes) => {
},
initialValue: {{{ CREATE_HISTORY }}},
});
- history = createHistory(ROUTER_BASE)
+ history = createHistory(ROUTER_BASE);
+ // 修改routes
+ plugin.applyPlugins({
+ key: 'patchRoutes',
+ type: ApplyPluginsType.event,
+ args: { routes },
+ });
router = createVueRouter({
history,
routes
diff --git a/packages/fes/package.json b/packages/fes/package.json
index 1ff77226..5ec9320f 100644
--- a/packages/fes/package.json
+++ b/packages/fes/package.json
@@ -1,6 +1,6 @@
{
"name": "@fesjs/fes",
- "version": "2.0.0",
+ "version": "2.0.1",
"description": "一个好用的前端管理台快速开发框架",
"preferGlobal": true,
"scripts": {
@@ -40,7 +40,7 @@
],
"dependencies": {
"@fesjs/compiler": "^2.0.0",
- "@fesjs/preset-built-in": "^2.0.0",
+ "@fesjs/preset-built-in": "^2.0.1",
"@fesjs/runtime": "^2.0.0",
"@umijs/utils": "3.3.3",
"resolve-cwd": "^3.0.0"