Open danielcompton opened 6 years ago
In the new version of the figwheel repl/server I'm using jetty so this certainly seems possible, SSL is also another possibility.
Another idea I had would be to somehow serve :optimisations :white-space
for initial page load (or just concatenate the files manually), but for all incremental reloads, serve only the updated files. That sounds pretty tricky though.
Yeah I thought about that a while back and it is very tricky.
Respectfully, I hope figwheel gains the ability to start an https service.
In the node ecosystem there are various key-generating tools such as this one. Throw-away keys are fine for development.
I think using HTTP2 would greatly improve the page load performance of projects using Figwheel. Anecdotal reports on Clojurians also suggest this is the case for ClojureScript dev projects. With HTTP 1.1, browsers will only open up to 6 requests at a time to a single origin. This means that lots of the static file requests end up blocked, waiting in line. With HTTP2, this wait would be eliminated as the browser can make many requests over a single stream.
It would be interesting to see what would be involved for Figwheel to serve assets over HTTP2, and to quantify the performance improvements. It would need to be an opt-in thing, because HTTP2 requires SSL, even in localhost, and setting that up can be a bit of a pain.