Skip to content

Commit

Permalink
fix(router): 修复初始路由参数未被传递的问题
Browse files Browse the repository at this point in the history
  • Loading branch information
Chen-jj committed Dec 4, 2020
1 parent 32ea25d commit 8ca8ab6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/taro-router/src/router.ts
Expand Up @@ -167,7 +167,7 @@ export function createRouter (
}

if (history.location.pathname === '/') {
history.replace(routes[0].path as string)
history.replace(routes[0].path as string + history.location.search)
}

render(history.location, 'PUSH')
Expand Down

0 comments on commit 8ca8ab6

Please sign in to comment.