update:修改router为histroymode
This commit is contained in:
18
package-lock.json
generated
18
package-lock.json
generated
@@ -3462,10 +3462,14 @@
|
||||
}
|
||||
},
|
||||
"node_modules/caniuse-lite": {
|
||||
"version": "1.0.30001177",
|
||||
"resolved": "https://registry.npm.taobao.org/caniuse-lite/download/caniuse-lite-1.0.30001177.tgz?cache=0&sync_timestamp=1610604244835&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fcaniuse-lite%2Fdownload%2Fcaniuse-lite-1.0.30001177.tgz",
|
||||
"integrity": "sha1-LDs4STOq/aA+KczKe7PYwzieHs4=",
|
||||
"dev": true
|
||||
"version": "1.0.30001300",
|
||||
"resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001300.tgz",
|
||||
"integrity": "sha512-cVjiJHWGcNlJi8TZVKNMnvMid3Z3TTdDHmLDzlOdIiZq138Exvo0G+G0wTdVYolxKb4AYwC+38pxodiInVtJSA==",
|
||||
"dev": true,
|
||||
"funding": {
|
||||
"type": "opencollective",
|
||||
"url": "https://opencollective.com/browserslist"
|
||||
}
|
||||
},
|
||||
"node_modules/case-sensitive-paths-webpack-plugin": {
|
||||
"version": "2.3.0",
|
||||
@@ -18441,9 +18445,9 @@
|
||||
}
|
||||
},
|
||||
"caniuse-lite": {
|
||||
"version": "1.0.30001177",
|
||||
"resolved": "https://registry.npm.taobao.org/caniuse-lite/download/caniuse-lite-1.0.30001177.tgz?cache=0&sync_timestamp=1610604244835&other_urls=https%3A%2F%2Fregistry.npm.taobao.org%2Fcaniuse-lite%2Fdownload%2Fcaniuse-lite-1.0.30001177.tgz",
|
||||
"integrity": "sha1-LDs4STOq/aA+KczKe7PYwzieHs4=",
|
||||
"version": "1.0.30001300",
|
||||
"resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001300.tgz",
|
||||
"integrity": "sha512-cVjiJHWGcNlJi8TZVKNMnvMid3Z3TTdDHmLDzlOdIiZq138Exvo0G+G0wTdVYolxKb4AYwC+38pxodiInVtJSA==",
|
||||
"dev": true
|
||||
},
|
||||
"case-sensitive-paths-webpack-plugin": {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { createRouter, createWebHashHistory } from "vue-router";
|
||||
import { createRouter, createWebHistory } from "vue-router";
|
||||
const files = require.context("@/views", true, /\.vue$/);
|
||||
let pages = [];
|
||||
const genRoutes = [];
|
||||
@@ -54,8 +54,7 @@ pages
|
||||
|
||||
const routes = [...genRoutes];
|
||||
const router = createRouter({
|
||||
history: createWebHashHistory(),
|
||||
history: createWebHistory("/spa"),
|
||||
routes
|
||||
});
|
||||
|
||||
export default router;
|
||||
|
||||
Reference in New Issue
Block a user