File tree Expand file tree Collapse file tree 1 file changed +12
-4
lines changed Expand file tree Collapse file tree 1 file changed +12
-4
lines changed Original file line number Diff line number Diff line change @@ -55,9 +55,13 @@ function addRouteRecord (
5555 // not be rendered (GH Issue #629)
5656 if ( process . env . NODE_ENV !== 'production' ) {
5757 if ( route . name && route . children . some ( child => / ^ \/ ? $ / . test ( child . path ) ) ) {
58- warn ( false , `Named Route '${ route . name } ' has a default child route.
59- When navigating to this named route (:to="{name: '${ route . name } '"), the default child route will not be rendered.
60- Remove the name from this route and use the name of the default child route for named links instead.`
58+ warn (
59+ false ,
60+ `Named Route '${ route . name } ' has a default child route. ` +
61+ `When navigating to this named route (:to="{name: '${ route . name } '"), ` +
62+ `the default child route will not be rendered. Remove the name from ` +
63+ `this route and use the name of the default child route for named ` +
64+ `links instead.`
6165 )
6266 }
6367 }
@@ -83,7 +87,11 @@ function addRouteRecord (
8387 if ( ! nameMap [ name ] ) {
8488 nameMap [ name ] = record
8589 } else if ( process . env . NODE_ENV !== 'production' ) {
86- warn ( false , `Duplicate named routes definition: { name: "${ name } ", path: "${ record . path } " }` )
90+ warn (
91+ false ,
92+ `Duplicate named routes definition: ` +
93+ `{ name: "${ name } ", path: "${ record . path } " }`
94+ )
8795 }
8896 }
8997}
You can’t perform that action at this time.
0 commit comments