Solve the problem of NavigationDulicated, navigating to current location (xxxx) is not allowed in the vue project

This is the routing problem. For the same route added in the route, we only need to rewrite the route.

You can introduce vue-router in the router file or main.js file, just add the following code

import Routers from "vue-router";


const routerPush = Routers.prototype.push
Routers.prototype.push = function push(location) {
	return routerPush.call(this, location).catch(error => error)
}

 

Supongo que te gusta

Origin blog.csdn.net/miao_yf/article/details/106756312
Recomendado
Clasificación