当用户从编辑页面单击时,我试图重新加载页面组件,路由器不重新加载,并且旧的编辑值仍然保留。
{
path: "/products/new",
component: ProductPage,
meta: {
breadcrumb: [
{ name: "Home", link: "/home" },
{ name: "Products", link: "/products" },
{ name: "New Product" }
]
}
},
{
path: "/products/:id",
component: ProductPage,
meta: {
breadcrumb: [
{ name: "Home", link: "/home" },
{ name: "Products", link: "/products" },
{ name: "Edit Product" }
]
}
}
当两个页面具有相同的组件时,有什么方法可以重新加载页面组件吗?
答案 0 :(得分:0)
使用this.$router.go({path:'/products', params:{id:id}})
...
import itertools
L1 = ["Eagle", "Panther"]
L2 = ["Warrior", "Talon", "Machete"]
L3 = ["Feather", "Raptor", "Hunter", "Piranha"]
for x in itertools.product(L1,L2,L3):
print(x)