The best experience I've had so far is #ParcelJS, it just works https://parceljs.org/languages/javascript/#service-workers
#bundler #javascript #webdev #parceljs
Parcel v2.9.0: package exports, ESM-based plugins and configs, incremental symbol propagation and more
https://parceljs.org/blog/v2-9-0/
#ES_Next_News #ECMAScript #JavaScript #ParcelJS
#es_next_news #ecmascript #javascript #parceljs
I now have 2 #JavaScript projects in which the scope hoisting https://parceljs.org/features/scope-hoisting/ feature of #ParcelJS is removing most of my own code and some imports from the production bundle.
The dev build via โwatchโ is always working fine.
I now disable the feature every time I run into this issueโฆ
Tree shaking seems to work still but this affects performance maybe a tiny bit.
Here is also the related issue https://github.com/parcel-bundler/parcel/issues/8792
Welp, having spun two small Typescript libraries off of #xinjs and build a tiny one from scratch, and published them to npm, in the last few daysโall using #parceljsโI finally felt I had facepalmed enough times to switch #xinjs over to building dist/ and cdn/ targets with parceljs. I guess I'll find out tomorrow if I've blown anything up.
There's a lot of reasons to like #parceljs but if there's one I'd pick over the others, it's eliminating the need to deal with multiple tsconfigs. If I weren't using ts-standard I wouldn't need to deal with ts-config at all.
#parceljs is amazingly convenient and easy to use but I built a tiny library (random-Iโd-base36) from a 4kB Javascript source file with no dependencies and it produced a 9kB file?!. Everything now has a giant name composed of random strings and $ signs. Like WTF?
So I tried #rollupjs and got better results without actually minifying.
Eventually I discovered that you need a little more configuration in #parceljs but now the only actual small file is neither module nor mainโฆ
#parceljs #rollupjs #javascript
I discovered that several tools I like including a web3 dev tool that didnโt suck and codesandbox (see below) use #parceljs for packaging. Parceljs is essentially a simple opinionated wrapper for the usual collection of garbage you need to package up front end projects. Paired with bun (which Iโve already raved about) you get very easy debug with watch and prod build for fairly arbitrary tech stacks (notably including non-React). Also, unlike โbun devโ it doesnโt crash.
Love it.
@actsukrit I also like #parcel #parceljs when I'm not feeling like using a full on framework. It's very simple to start with and just takes plain old HTML, JS, MD etc and packages it up into nice pre-processed, bundled, and minified static files.