-
Notifications
You must be signed in to change notification settings - Fork 393
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
pageerror at /: SyntaxError: Unexpected token '.' #557
Comments
Hi @aakashpgandhi I am getting a similar error. Have you been able to resolve it? |
Hey @aakashpgandhi @chrismadufor everything was working fine for me for the last year until today that I started getting this error, without any changes to the node version & packages 🤷🏽♂️ Did you find any solution? |
same issue here with vite |
Hi! Thanks! |
I'm seeing |
same one react-snap 🔥 pageerror at /: SyntaxError: Unexpected token '?' ✅ crawled 1 out of 1 (/) |
any solution |
same here |
same for me using |
I had a similar error and I solved it with this configuration in the
|
Hi, on my side, the issue was not directly due to react-snap. I got My potential explanation: However, as react snap is using puppeteer, I think the browser was not able to handle I did this to make it work perfectly with vitejs : vitejs/vite#10519. PS: I had to test my code on very old iPad using old safari version to be able to found the solution. Once it worked on the device, it was working also with pupeteer. I say this because depending on the error, maybe you can resolve it without changing compilation options and just change the JS notation used (I think about function declaration using PPS: to better found error source, use |
Hi, I have the same issue, however it seems that on my side react-i18next is the responsible for this. It's very likely that it's using newer syntax that react-snap's puppeteer process does not like. Putting this here for anyone that might run into this. |
Same problem. |
see #577 (comment) from #577 - hope it helps! |
pageerror at /: SyntaxError: Unexpected token '.'
at Object../node_modules/usehooks-ts/dist/esm/useEventListener/useEventListener.js (http://localhost:45678/main.js:14103:1)
at webpack_require (http://localhost:45678/main.js:19980:42)
at eval (webpack://frontend/./node_modules/usehooks-ts/dist/esm/useEventListener/index.js?:5:75)
at Module../node_modules/usehooks-ts/dist/esm/useEventListener/index.js (http://localhost:45678/main.js:14092:1)
at webpack_require (http://localhost:45678/main.js:19980:42)
at eval (webpack://frontend/./node_modules/usehooks-ts/dist/esm/useClickAnyWhere/useClickAnyWhere.js?:5:75)
at Module../node_modules/usehooks-ts/dist/esm/useClickAnyWhere/useClickAnyWhere.js (http://localhost:45678/main.js:13927:1)
at webpack_require (http://localhost:45678/main.js:19980:42)
at eval (webpack://frontend/./node_modules/usehooks-ts/dist/esm/useClickAnyWhere/index.js?:5:75)
✅ crawled 1 out of 1 (/)
i am getting this error while running npm run postbuild
The text was updated successfully, but these errors were encountered: