2 ms·
Compatible with spec and previously a feature. I agree that it should be patched but Chrome's policy has historically made local web development and testing a p
by kevingadd 7y ago
Compatible with spec and previously a feature. I agree that it should be patched but Chrome's policy has historically made local web development and testing a pain in the ass because now you have to configure a web server correctly and work around Chrome's broken cache-control policy (have fun ctrl-f5'ing all the time or opening devtools to disable cache, which deoptimizes your JS)
I struggled with this for years and opened multiple bugs about it. If you're trying to release software to end-users that requires them to configure a whole damn web server you get really tired of it.
Disabling content loading from file:// is one solution, but I feel like the 'this was loaded from the internet' flag already used for downloaded EXEs and DLLs is a perfectly reasonable alternative that would work just as well without breaking things for local development. (To be clear, you don't offer the option to bypass that, since it would only be a security vulnerability)
- ChrisSD 7y agoDoes`python -m http.server 8000` not work for local development?
- kevingadd 7y agoYou need way more configuration than that, python's http server doesn't handle keepalive and threading correctly (or didn't when I last used it, maybe that's fixed in 3). I historically had to use IIS or Apache, and at work we used a full Apache install. If you used python your performance was much worse if your application worked at all. For C# apps you can at least just spin up a HTTPD directly in your app using system APIs, but it's also kind of flaky.