feat(product): change router history driver, change add to cart behaviour
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import {createMemoryHistory, createRouter} from 'vue-router';
|
||||
import {createRouter, createWebHistory} from 'vue-router';
|
||||
import Home from './views/Home.vue';
|
||||
import Product from './views/Product.vue';
|
||||
import CategoriesList from "./views/CategoriesList.vue";
|
||||
@@ -13,12 +13,13 @@ const routes = [
|
||||
{path: '/products/:category_id', name: 'product.categories.show', component: Products},
|
||||
{path: '/categories', name: 'categories', component: CategoriesList},
|
||||
{path: '/category/:id', name: 'category.show', component: CategoriesList},
|
||||
{path: '/cart', name: 'cart.show', component: Cart},
|
||||
{path: '/cart', name: 'cart', component: Cart},
|
||||
{path: '/checkout', name: 'checkout', component: Checkout},
|
||||
{path: '/success', name: 'order_created', component: OrderCreated},
|
||||
];
|
||||
|
||||
export const router = createRouter({
|
||||
history: createMemoryHistory('/image/catalog/tgshopspa/'),
|
||||
// history: createMemoryHistory('/image/catalog/tgshopspa/'),
|
||||
history: createWebHistory('/image/catalog/tgshopspa/'),
|
||||
routes,
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user