vuejs / router

🚦 The official router for Vue.js
https://router.vuejs.org/
MIT License
3.91k stars 1.19k forks source link

中文路径刷新时匹配不到路径 #1987

Closed Preyou closed 1 year ago

Preyou commented 1 year ago

Reproduction

Steps to reproduce the bug

带有中文路径的路由

Expected behavior

刷新后进入当前路由

Actual behavior

进入404路由

Additional information

这里,非英文会被编码,因此要先解码再匹配,这一行应该改成这样 push(decodeURI(routerHistory.location))

posva commented 1 year ago

Don't open issues without reproductions. Thanks.