stereobooster / react-snap

👻 Zero-configuration framework-agnostic static prerendering for SPAs
MIT License
5.04k stars 391 forks source link

CORS policy #435

Closed marioliu closed 4 years ago

marioliu commented 4 years ago

I get this error during postbuild when react-snap is running:

Access to XMLHttpRequest at 'https://website' from origin 'http://localhost:45678' has been blocked by CORS policy

Is there a way to disable CORS for the headless Chrome running in react-snap?

marioliu commented 4 years ago

Got it, you just pass in --disable-web-security in the puppeteerArgs array