Skip to content

Commit 1a34618

Browse files
author
Guillaume Chau
committed
fix: restore route making a view unnavigable
1 parent ebc0ea2 commit 1a34618

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

packages/@vue/cli-ui/src/mixins/RestoreRoute.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,9 @@ export default function ({
3939
},
4040

4141
beforeRouteLeave (to, from, next) {
42-
lastRoute = from
42+
if (from.params && Object.keys(from.params).length) {
43+
lastRoute = from
44+
}
4345
next()
4446
},
4547

0 commit comments

Comments
 (0)