Esbuild – An extremely fast JavaScript bundler
21–30 of 288 posts
Re: Esbuild – An extremely fast JavaScript bundler
#22ESbuild is getting fantastic traction. It’s the default in Phoenix from 1.6 and comes as a default option in the current alpha of Rails 7, which you can get with a simple rails new your_app -j esbuild The only sort of issue I’ve had with it so far is you can’t use it with Inertiajs[1] as it does not support dynamic imports out of the box. Although I’m hesitant to call it an issue if its not in the scope of the projec…
Re: Esbuild – An extremely fast JavaScript bundler
#23Are there any tools that transform HTML and other files? For example, lets say I have an tag with a src attribute that points to a local image. Can I automatically replace that with a tag with various formats (jpg, webp, avif) and sizes?
Re: Esbuild – An extremely fast JavaScript bundler
#24What do you think of the importmap approach propagated by dhh on rails 7?
Re: Esbuild – An extremely fast JavaScript bundler
#25ESbuild is getting fantastic traction. It’s the default in Phoenix from 1.6 and comes as a default option in the current alpha of Rails 7, which you can get with a simple rails new your_app -j esbuild The only sort of issue I’ve had with it so far is you can’t use it with Inertiajs[1] as it does not support dynamic imports out of the box. Although I’m hesitant to call it an issue if its not in the scope of the projec…
Esbuild w/rails 7 is nice, but if you’re using rails, check out vite_ruby [1]. I used it in a side project and it comes with plugins for views HMR + all the good stuff that comes built into vite. 1: https://github.com/ElMassimo/vite_ruby
I’d go so far as to say I wish -j vite was an option in js-bundling :)
Re: Esbuild – An extremely fast JavaScript bundler
#26Re: Esbuild – An extremely fast JavaScript bundler
#27Re: Esbuild – An extremely fast JavaScript bundler
#28Isn't the browser also an extremely fast Javscript bundler? How many scripts does a site need to make it feel faster when bundled? When I visit websites that are rendered serverside, they usually feel instant to me. Even when they load a dozen scripts or so.
- fast TypeScript/JSX compile
- bundling shared code to reduce request waterfall/splitting to reduce redundancy
- bundle optimization (tree shaking/dead code elimination; minification is actually faster than not using it)
- a simple plugin system for use cases like other compiled frameworks like Vue or Svelte, or whatever else you might want in a build pipeline
Re: Esbuild – An extremely fast JavaScript bundler
#29I would rather use Parcel.
Re: Esbuild – An extremely fast JavaScript bundler
#30Earlier quoted context omitted.
> How many scripts does a site need to make it feel faster when bundled? Depends on what you're building. If you have many nested dependencies, you need to bundle them, and not rely on the browser to resolve them at runtime and do dozens of roundtrips to the server to fetch them.
I thought HTTP 2 fixed the problem of multiple downloads of small files/dependencies? The creator of Rails talks about it here: https://world.hey.com/dhh/modern-web-apps-without-javascript...