stereobooster/react-snap

pagerror and incomplet crawled page with firestore

harrymelka opened this issue · 4 comments

Hey,
I have been trying to integrate react-snap with our project but it doesn't work as expected with our project.

We are using create-react-app, firebase, axios, react-router, redux and much more but the main issue we have is that it does not generate all the files and requests are not working

Screenshot 2022-03-09 at 17 13 03

The website itself is working very nicely and the goal is to generate the static website for SEO performance.

The first issue is that the firebase request is not fetching data. All the request are not working. So it can't fetch all the dynamic elements to build dynamic urls of pages.

Also react-snap detect that there is 12 pages to crawle but it jumped directly from 1 to 11 and gets the /areas/0 which is dynamic that one and it goes up to 4.

This is my config inside package.json, I tried all the solution but nothing is working.

Screenshot 2022-03-09 at 17 32 46

I have also tried changing version of react-snap from 1.10 to the latest one. I have tried to include all the routes inside the "include" param in package.json. I have tried to do it with a custom script like this https://karannagupta.com/using-custom-workbox-service-workers-with-create-react-app/

I spent hours on all the git issues and now I am really stuck and considering going to next.js if I have no other way but still having hope in react-snap.

If anyone had this issue your help could be really appreciated

No need I fixed it

@harrymelka Hey, can u explain how you solved this issue? I have same problem.

@jaeger-dvlp hey, you need to be sure you are handling routing like it's written in the documentations. Me I replace all the navigate with and then it was working.

@harrymelka , thanks bud. I'll try my shot.