mirror of
https://github.com/nuxt/nuxt.git
synced 2025-01-18 09:25:54 +00:00
fix(nuxt): do not warn about invalid characters in route groups/catchalls
This commit is contained in:
parent
06d5840d26
commit
5be18cf4b0
@ -424,7 +424,7 @@ function parseSegment (segment: string, absolutePath: string) {
|
|||||||
state = SegmentParserState.initial
|
state = SegmentParserState.initial
|
||||||
} else if (c && PARAM_CHAR_RE.test(c)) {
|
} else if (c && PARAM_CHAR_RE.test(c)) {
|
||||||
buffer += c
|
buffer += c
|
||||||
} else {
|
} else if (state === SegmentParserState.dynamic || state === SegmentParserState.optional) {
|
||||||
logger.warn(`'\`${c}\`' is not allowed in a dynamic route parameter and has been ignored. Consider renaming \`${absolutePath}\`.`)
|
logger.warn(`'\`${c}\`' is not allowed in a dynamic route parameter and has been ignored. Consider renaming \`${absolutePath}\`.`)
|
||||||
}
|
}
|
||||||
break
|
break
|
||||||
|
Loading…
Reference in New Issue
Block a user