How could store products and Category url same for PWA and web
I was trying to implement PWA as alternative of native mobile app .. but can see one problematic with URL are different for PWA and web !!
due to its different it having difficulties redirection of url conversion , say I want to refer one product /category link to somewhere say in facebook store and wanted to redirect same product page in PWA for mobile user !! So How could achieve store products and Category url same for PWA and web !!
Example: for PWA it appears like 'categories/7' and for web its '/electronics'
also for product url:
for PWA 'products/5' and for web '/black-headphones'
shubhwebkul last edited by
We have not implemented the functionality you are referring in PWA.
You have to create a new route in vue.js, and hit the newly created api with response the details which will contain the type (product / category) and further details of that.
On the basis of response you can call the template.
Let me know if you have any further query.
Still not clear how to achieve that , can you please give code example .
shubhwebkul last edited by shubhwebkul
add a route here with path (path: '/:slug',) for redirection on the click of product and category, and create a component as well.
after that hit the api (create a new one to fetch details) and render details based on the data fetched from the API.
I am still finding a way how to route / redirect web store page to pwa store page..
say with same storepage from web front store it will be redirect to pwa ..
above use case is for mobile user .
say for ..
can you please share development way with code example?