daquinoaldo/https-localhost

CORS Support

blainsadler opened this issue · 0 comments

How would you like to expand the functionalities?

When using https-localhost to serve static assets that are loaded by another locally served application via XMLHttpRequest browsers reject the request due to the lack of CORS headers on the response. I'd like to add CORS support so local frontend application development can take advantage of the ease of https-localhost.

Are there alternatives?

You can write a wrapper around https-localhost which adds this functionality, however in the spirit of a quick and easy local https server including this by default seems like a win.

Is it a breaking change?

No, all existing usages will continue to work.