refactor: modifyCreateHistroy更改为modifyCreateHistory

This commit is contained in:
wanchun 2022-04-19 19:50:58 +08:00
parent a29b021190
commit f7185ea24e
3 changed files with 4 additions and 4 deletions

View File

@ -14,7 +14,7 @@ export function modifyClientRenderOpts(memo) {
}; };
} }
export function modifyCreateHistroy(memo) { export function modifyCreateHistory(memo) {
if (history.url) { if (history.url) {
return createMemoryHistory return createMemoryHistory
} }

View File

@ -29,8 +29,8 @@ export default function (api) {
'render', 'render',
// 修改路由 // 修改路由
'patchRoutes', 'patchRoutes',
// 修改histror // 修改history
'modifyCreateHistroy', 'modifyCreateHistory',
// 生成router时触发 // 生成router时触发
'onRouterCreated' 'onRouterCreated'
] ]

View File

@ -14,7 +14,7 @@ export const createRouter = (routes) => {
return router; return router;
} }
const createHistory = plugin.applyPlugins({ const createHistory = plugin.applyPlugins({
key: 'modifyCreateHistroy', key: 'modifyCreateHistory',
type: ApplyPluginsType.modify, type: ApplyPluginsType.modify,
args: { args: {
base: ROUTER_BASE base: ROUTER_BASE