-
-
Notifications
You must be signed in to change notification settings - Fork 500
Warning vue router #57
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Hi @javialon26, what does the files structure look like in your pages directory? |
@paulgv this is the pages directory and now the same warning happens with all pages inside ayuda directory. The warning appears when i enter the route. |
Same problem here! https://www.dropbox.com/s/d92gabryix5hk4b/Selection_009.png?dl=0 |
I fixed the problem by rewrite this code. const routeName = route && route.name ? app.getRouteBaseName() : 'index'; |
After the update the warning is still showing but i found the problem. I have a custom breadcrumb component with a localePath method in a nuxt-link tag. The name param is taken from the store and the value is loaded in a middleware with the value of route.name, this value already has -es or -en suffix and when is passed to localePath the suffix is added again. This will be fixed or i need to take care of this in my own code? Thank you! |
any news on this? |
Hi @javialon26 ! |
@paulgv you right, now i pass the route name directly to nuxt-link and everythings is ok. thank you! |
I have the same issue, I opened another ticket for it though. Can't make i18n to work (Cannot continue my project without it) - Ignore the first part I was setting it up the 'old' way (I found that 6 hours later :P) |
this.$router.push(this.localPath('/path')) I get the same warnging again. |
@paulgv I'm still experiencing this issue with the '[vue-router] Route with name x does not exist' whenever I manually set enabled locales in the component. It seems the error is generated in every case where localePath is used: the only way to get rid of the warnings altogether is if I set SEO: false, remove all links with localePath and remove the language switcher so it seems like a warning is generated anywhere localePath is called. Do you have any idea how to fix this? Or @moecasts, could you repost the change you mentioned here #57 (comment) ? |
i have the same problem, usually happens after rebuild. i was able to narrow down the problem to this code:
when rebuild starts |
The same for me, as @pkorzh has, started after I’ve updated nuxt to v2.* |
Same here but only with hash key as @pkorzh and @cyxapb1280
Also with Nuxt 2.*, I'll try Nuxt 1 EDIT |
So what is the solution for this issue when it's closed? I get millions of these warnings because the generation of the alternate links. |
Found #14 |
i'm with this problem. Anybody has solution to fix this? |
// Routes generation strategy, can be set to one of the following: |
Problem still persists. But so far all I can do as
|
You can fix this problem by installing @nuxtjs/router-extras and set a custom name for the route like this : |
Same problem here |
@paulgv The described issue in this thread is still existent, though it got closed. |
This issue is very old and a lot has changed since the initial report so I'm not sure if your issue is even related. Please create a new issue for your problem with a reproduction repo (or codesandbox). |
Is is still happening with the latest version of nuxt and router. |
@paulgv we just need to disable the warnings. 2022 and it's still going on. |
to all, in my case it was just about redoing a npm run dev / build and all is ok |
This continued on August 9, 2023 @paulgv |
In all routes with more than one level i have this warning:
[vue-router] Route with name 'usuario-editar-perfil-es-es' does not exist
Examples:
Route: http://localhost:3000/usuario/editar-perfil
[vue-router] Route with name 'usuario-editar-perfil-es-es' does not exist
Route: http://localhost:3000/usuario/mis-anuncios
[vue-router] Route with name 'usuario-mis-anuncios-es-es' does not exist
But in routes with only one level it is okay, for example:
http://localhost:3000/ayuda
http://localhost:3000/quienes-somos
My Nuxt version is 1.4.0 and nuxt-i18n version is 2.9.1.
Configurations:
The text was updated successfully, but these errors were encountered: