-
-
Notifications
You must be signed in to change notification settings - Fork 108
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
Cannot GET due to Content Security Policy #24
Comments
I had someone else on a windows machine test and they had the same result. We were able to get it working by doing the following though:
Not sure if something in the script needs to be tweaked to allow it to run from a single terminal? |
I am not able to reproduce this issue. Could you provide your node version, browser, and operating system? Also, your package.json would be helpful. |
Software versions
package.json
|
Hello @curtisbarnard Can you try it on the latest Node 17x? Also, try upgrading all dependencies. |
I was able to reproduce the issue. From what I can tell, it seems that browser-sync is not finding the folder for some reason and the empty page is generating a CSP warning. I was also able to reproduce the error using this simplified test without npm-run-all, tailwind, or eleventy just to help narrow the issue down.
When running I did find that removing the single quotes around the Try changing the browsersync script to this: The browser-sync documentation examples use single quotes, so I'm not sure why this is happening. In any case, let us know if this fixes the issue. |
I just tried @wiredacorn suggestion of removing the single quotes from the package.json and it worked like a charm! Would you like me to open a PR to make this change? |
@surjithctly I tried it with node 18.2.0 and still had the same issue. Again removing the ticks from |
I see. Can you open a PR? |
Sorry I'm new to node so perhaps I did something wrong. I followed the directions here: https://blog.surjithctly.in/neat-stack-create-a-static-website-with-netlify-cms-eleventy-alpinejs-and-tailwindcss
When I run
npm run start
and go to http://localhost:8080 to see the served site I'm getting "Cannot GET /" on the page with the following error in the console:When I look in the HTML source I see it is blocking this bit of code:
I'm a bit confused as to where to look to fix the issue. Thanks for the help!
The text was updated successfully, but these errors were encountered: