Categories
How to specify the path to a non-existent page?
Usually we specify paths to various pages in routes. How to specify the path to the page, in this case the error page, if the path specified by the user does not exist?
Answer the question
In order to leave comments, you need to log in
const routes = [ ... { path: '*', component: Page404, }, ];
const routes = [ ... { path: '/404', component: Page404, }, { path: '*', redirect: '/404', }, ];
Didn't find what you were looking for?
Ask a Question
731 491 924 answers to any question