Theo's main point is that const doesn't mean "this value will never change" (since objects and arrays can obviously still be mutated), but that let means "pay attention, this value will be reassigned further down", and I totally agree.
Useful snippet for computing pixel dimensions from paper sizes (both metric (DIN) and (US) imperial presets included) using https://thi.ng/units, an elaborate & powerful unit converter/calculator/DSL for all SI dimensions:
Kitten now has a lovely new multi-page Settings screen and… drumroll… a new 🐢 interactive shell (REPL) for you to play with the running state of your Small Web site/app/place and debug your app, inspect/manipulate its database, etc.
I plan on recording demos of each of them tomorrow but you can play with them now.
And here’s a little tutorial to get you started with the shell:
It's been almost a decade since I've done a live coding stream. This will be fun!
Today I'll be migrating my website from React to Lit, which is a lightweight framework built around web components. I have the scaffolding set up mostly, so now it's time to get this done.
Come watch. Ask questions in chat! You don't need to create an account, just a username is needed to participate.
I know he didn't explain his position in details, so a 1800-word article sounds a little unfair, but I think dry and sharp statements need adequate context and analysis.
Another leak in the JavaScript single-threaded facade (or a bug in Jest, really).
Asserting expect(...).toStrictEqual(...) fails with two structurally identical objects created by two different Node worker threads because their prototypes are not the same (though identical). Asserting expect(structuredClone(...)).toStrictEqual(structuredClone(...)) works.
Enhancing my JavaScript knowledge bit by bit - today with a fun short clip by @cferdinandi and @kevinpowell; explaining var, let, and const - and when/where to use them for declaring a variable.
Last month's exclusive video at The Spicy Web demonstrating a CodePen example of Signals—what they are, how they work, and why frontend frameworks and fans of vanilla #JS alike are adopting them rapid-fire—is now available to view for free! Check it out:
Here be a fresh (and tingly!) take on reaching for #HTML-first tools like htmx, Turbo, Unpoly, etc. and why you might just want to (spoiler alert!) go vanilla. 🍦 After all, we have so many great browser-native APIs at our disposal now! #JavaScript#WebDev