Answer the question
In order to leave comments, you need to log in
How to make a 404 page in VUE.js?
Good evening!
The crux of the question is how to implement a 404 page through vue-router.
There are prescribed paths, and it is necessary that all urls that are not registered in the paths are redirected to the 404 page.
Even nothing comes to mind, I can’t find examples on the Internet, but I don’t understand Chinese yet).
Answer the question
In order to leave comments, you need to log in
const routes = [
...
{
path: '/404',
name: '404',
component: NotFound,
}, {
path: '*',
redirect: '/404'
}
]
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question