Does Route Interception work on route groups / dynamic routes or am I doing something wrong?
Unanswered
Basset Artésien Normand posted this in #help-forum
Basset Artésien NormandOP
So our application structure is as follows (refer to the first image for context).
We have a store page (refer to the second image), that renders a store template component (refer to the third image), within our store template we have a paginated products component (refer to the fourth image) that renders a grid of product preview components (refer to the fifth image) that points to the url of the products page.
The products page renders a products template component, that displays product details (refer to the 6th image for context).
Our goal is to intercept the products route from our store route, and display the product page in a modal over the store page. However, whenever the user clicks on the add to cart button in the product preview component, they are simply redirected to the products page and the route is not intercepted:
We have a store page (refer to the second image), that renders a store template component (refer to the third image), within our store template we have a paginated products component (refer to the fourth image) that renders a grid of product preview components (refer to the fifth image) that points to the url of the products page.
The products page renders a products template component, that displays product details (refer to the 6th image for context).
Our goal is to intercept the products route from our store route, and display the product page in a modal over the store page. However, whenever the user clicks on the add to cart button in the product preview component, they are simply redirected to the products page and the route is not intercepted:
✓ Compiled /[countryCode]/products/[handle] in 7.5s1 Reply
Sorry that this isn't helpful, but I can spot no issues in your code, and my very similar project is set up the same way and works.