mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-22 05:35:13 +00:00
fix(nuxt): pass undefined
name when resolving trailing slash (#26358)
This commit is contained in:
parent
8d6eab4822
commit
c49d206647
@ -113,14 +113,10 @@ export function defineNuxtLink (options: NuxtLinkOptions) {
|
||||
|
||||
const resolvedPath = {
|
||||
...to,
|
||||
name: undefined, // named routes would otherwise always override trailing slash behavior
|
||||
path: applyTrailingSlashBehavior(path, options.trailingSlash)
|
||||
}
|
||||
|
||||
// named routes would otherwise always override trailing slash behavior
|
||||
if ('name' in resolvedPath) {
|
||||
delete resolvedPath.name
|
||||
}
|
||||
|
||||
return resolvedPath
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user