News for hackers. Stuff that matters.
Re:Snowpack: Build a web application without a bundler by JMTQp8lwXL on Wednesday January 08, 2020 @07:15PM (#21997220)
Unpopular opinion: It isn't that bad. If you understand the purpose of a bundler and you understand the purpose of a transpiler, it's not difficult to understand how to put two and two together. You, for example, write ES6, you use babel to transpile to ES5, and webpack collapses all the require(...) calls into a smaller set of files (maybe even a single file, depending on your configuration).

It's all well documented, so if you need further details, there's nothing magic about these tools.

If you really don't want to be bothered with it, just use create react app, vue cli, or angular cli. Some people aren't that interested tooling, I get it.

Re:Snowpack: Build a web application without a bundler by JoshTriplett on Wednesday January 08, 2020 @07:19PM (#21997245)
> write ES6, you use babel to transpile to ES5

If you have the luxury to only care about modern browsers, do you need to bother transpiling? Every modern browser supports ES6 natively.

> and webpack collapses all the require(...) calls into a smaller set of files

Also less of an issue if you're using http/2 or http/3.

Is there a "preview of the future" framework out there that people can use if they want to see what a world looks like that doesn't have to work around old browsers?

Re:Snowpack: Build a web application without a bundler by julienb_sea on Wednesday January 08, 2020 @07:26PM (#21997295)
The whole point of this snowpack framework is that if you only care about modern browsers, everything is clean and collapsed. No compilation needed of your application code.
Re:Snowpack: Build a web application without a bundler by JMTQp8lwXL on Wednesday January 08, 2020 @07:21PM (#21997262)
There are people making applications with requirements where we have to support the legacy browsers, unfortunately. That's how Enterprise goes (but even large consumer-facing apps have the same requirements too, I would be shocked if Facebook "didn't work" on IE 11 today).

In my particular case, my infrastructure team will not, and has no plans on, enabling HTTP/2 in our upstream servers. The joy of application development at scale. You can't get everything you want, unless you control it all. Things are too distributed for me to practically sell the team on HTTP/2.

Re:Snowpack: Build a web application without a bundler by JoshTriplett on Wednesday January 08, 2020 @08:09PM (#21997533)
I understand that, and I know that such an approach wouldn't work for everyone. But it's worth looking at what the future could look like.
Re:Snowpack: Build a web application without a bundler by Aeolun on Wednesday January 08, 2020 @07:32PM (#21997331)
Hire an expensive consultant to tell them what they need to hear. I’m sure if they pay $100k for the privilege of hearing they need HTTP/2 they’ll be more receptive to the need.
Re:Snowpack: Build a web application without a bundler by corebit on Thursday January 09, 2020 @01:57PM (#22004257)
I am an expensive consultant. My advice is skip HTTP/2. Either wait for HTTP/3 to ditch TCP or start inlining resources into single HTML documents to reduce round trips.
Re:Snowpack: Build a web application without a bundler by JoshTriplett on Thursday January 09, 2020 @03:34PM (#22005369)
What motivates that advice?

I'm definitely looking forward to HTTP/3, but I anticipate HTTP/3 having more problems with adoption due to overzealous firewalls and UDP blocking. I expect a longer tail of "I can't use HTTP/3" clients than "I can't use HTTP/2" clients, which means it'll be longer before you can reasonably count on it for performance optimization.