David Gonzalez
dglez.es
David Gonzalez
@dglez.es
Software engineer.
Reposted by David Gonzalez
i scored 21/28 on jsdate.wtf only because i know javascript is completely unhinged so i just picked the most unreasonable answers to every question
new Date("wtf")
How well do you know JavaScript's Date class?
jsdate.wtf
July 19, 2025 at 9:42 PM
Reposted by David Gonzalez
Proxies might be my favorite JavaScript feature. Every so often I come across a seemingly impossible problem and they end up the answer. How about a mutable primitive that doesn't mutate any source without constantly cloning the tree.
playground.solidjs.com/anonymous/76...
Solid Playground
Quickly discover what the solid compiler will generate from your JSX template
playground.solidjs.com
July 9, 2025 at 7:57 PM
Reposted by David Gonzalez
oh and did you read about developer complaints about how Copilot refuses to work with code that has words like "gender"?

it's beyond ridiculous, all of this
Copilot stops working on `gender` related subjects · community · Discussion #72603
As some people already mentioned here or here, Copilot purposely stops working on code containing hardcoded banned words from Github such as gender or sex. I am labelling this as a bug because this...
github.com
June 28, 2025 at 11:45 AM
Reposted by David Gonzalez
⚡️ Vite 7.0 is out!

- Browser Target Changed to Baseline Widely Available
- Node 18 support dropped. Vite is now distributed as ESM only
- And feats, fixes, and cleanups, while we prepare for rolldown!
Vite 7.0 is out!
Vite 7 Release Announcement
vite.dev
June 24, 2025 at 12:10 PM
Reposted by David Gonzalez
#JavaScript: With hand-written HTML, I sometimes use this snippet:

for (const hx of document.querySelectorAll('h1[id],h2[id],h3[id],h4[id],h5[id],h6[id]')) {
hx.innerHTML = `${hx.innerHTML}`;
}

Not “cleanest” but simple. Ideas for simplifying more?
June 15, 2025 at 1:11 PM
Reposted by David Gonzalez
This little package by @antfu7 saves me so much time

I personally use pnpm
My clients use yarn
I still need npm sometimes

github.com/antfu-colle...
GitHub - antfu-collective/ni: 💡 Use the right package manager
💡 Use the right package manager. Contribute to antfu-collective/ni development by creating an account on GitHub.
github.com
June 13, 2025 at 5:59 AM
Reposted by David Gonzalez
#tinyCSStip One thing that has always annoyed me about `:empty` is that it doesn't work for elements that have text content, but no element children.

`:has()` fixes this problem.

`:not(:has(*))` selects elements that don't have element children, even if they have text content.
March 12, 2024 at 9:18 AM
Reposted by David Gonzalez
To everyone who didn't try Oxlint yet, there is no excuse anymore 👀

Thanks to all contributors 🙌🏻
Can't wait to see the changes on the roadmap tackled!
We're thrilled to announce the first stable release of Oxlint - version 1.0!

Our Rust-powered JavaScript/TypeScript linter delivers 50~100x faster performance than ESLint with 500+ rules and zero configuration required.

Time to give it a try!

voidzero.dev/posts/announ...
Announcing Oxlint 1.0
The first stable version of Oxlint, a fast & easy-to-use Rust-powered linter for JavaScript and TypeScript, is out. Learn about its 50~100x speed advantage over ESLint, support for 500+ rules, real-wo...
voidzero.dev
June 10, 2025 at 11:30 AM
Reposted by David Gonzalez
Today's 🌶️ take

#JSX support in the browser would most likely be a net positive

I don't mean


I mean


HTML anchored syntax in JS

It would be property-based, not attribute-based

CSP-safe

Don't come at me, it's just an idea 😅

#javascript #webdev #dev #frontend
May 24, 2025 at 8:51 PM
Reposted by David Gonzalez
View transitions are mind-blowing. The absolute trivial amount of JavaScript it takes to make this shuffling effect work is astounding.

I mean, I actually spend more lines *changing the background color* than I do moving elements around! 🤯

codepen.io/collinsworth...
Moving squares on a grid with view transitions
Just a fun experiment with `startViewTransition`. I realize this could all be done with less JS, but playing around with the API was the whole purpose....
codepen.io
May 21, 2025 at 4:02 PM
Reposted by David Gonzalez
Just a reminder – Sonda is a bundle visualizer and analyzer that works with all major bundlers (@vite.dev, Rollup, esbuild, webpack, @rspack.dev) and most popular JavaScript meta-frameworks (@nextjs.org, @nuxt.com, @astro.build, @svelte.dev Kit, @angular.dev CLI).

sonda.dev
Sonda
Universal visualizer and analyzer for JavaScript and CSS bundles. Works with Vite, Rollup, webpack, Rspack, and esbuild
sonda.dev
May 21, 2025 at 5:59 PM
Reposted by David Gonzalez
Have you ever wished the browser would look at a background color and pick black or white for the text — whichever one provides more contrast?

Now, the `constrast-color()` function in CSS does just that.

webkit.org/blog/16929/c...
How to have the browser pick a contrasting color in CSS
Have you ever wished you could write simple CSS to declare a color, and then have the browser figure out whether black or white should be paired with that color?
webkit.org
May 13, 2025 at 6:28 PM
Reposted by David Gonzalez
just released v2 alpha of Nuxt Image!

🙏 feedback wanted
💪 improved, stronger types
🚧 better provider types before release

please try it out and let us know how it goes for you!

github.com/nuxt/image/r...
Release v2.0.0-alpha.1 · nuxt/image
This is an alpha version of Nuxt Image v2 👀 Highlights We'd love your feedback! This release contains quite a lot of changes, including (of course) breaking changes. It also brings a great deal of...
github.com
May 5, 2025 at 10:10 AM
Reposted by David Gonzalez
🚀 Bundler Explorer is here (preview)!

Quickly create minimal demos for @rolldown.rs, Rollup, esbuild, and (coming soon) @rspack.dev!

Perfect for testing, debugging, or just exploring bundler behavior.

👉 Try it now bundler.sxzz.dev
bundler.sxzz.dev
April 17, 2025 at 6:07 AM
Reposted by David Gonzalez
😉 Just got a new domain for AST Explorer: ast-explorer.dev!

ast-explorer.dev
AST Explorer
A web tool to explore the ASTs generated by parsers.
ast-explorer.dev
March 3, 2025 at 1:34 PM
Reposted by David Gonzalez
this is really cool, akin to blurhash but it's implemented entirely in css
leanrada.com/notes/css-only…
Minimal CSS-only blurry image placeholders
leanrada.com
April 3, 2025 at 1:56 AM
Reposted by David Gonzalez
today's @e18e.dev cleanup tip!

rimraf - 3.7MB install size, 41 packages
premove - 9.7KB install size, 1 package

and if you're using it programmatically, just use node's own `fs.rm`!
March 22, 2025 at 9:53 AM
Reposted by David Gonzalez
How to Do Visual Regression Testing in Vue With Vitest?, by @alexanderopalic@x.com:

https://alexop.dev/posts/visual-regression-testing-with-vue-and-vitest-browser/

#howtos #testing #regressions #vuejs #vitest
How to Do Visual Regression Testing in Vue With Vitest?
alexop.dev
March 16, 2025 at 8:30 AM
Reposted by David Gonzalez
A #WebAssembly Compiler That Fits in a Tweet — Or 192 bytes, if you prefer. This is a look into a fantastic little bit of JavaScript hacking... || #JavaScript #WebDev
A WebAssembly compiler that fits in a tweet
Starting with a 192-byte one-liner that implements a Reverse Polish Notation arithmetic compiler, we'll work backward to transform it into readable JavaScript by removing one code golf trick at a time
bit.ly
March 3, 2025 at 10:50 PM
Reposted by David Gonzalez
Lint plugins are now available 🎉
February 19, 2025 at 4:18 PM
Reposted by David Gonzalez
cs16.css is a #CSS library based on...



...Counter Strike 1.6 UI. Neat.

cs16.samke.me #webdev
cs16.css
CSS library based on Counter Strike 1.6 UI.
cs16.samke.me
January 24, 2025 at 6:18 PM
Reposted by David Gonzalez
Does anyone else with multi-million-line typescript codebases notice that type-aware lint-rules double the time it takes ESLint to run?

Is there hope? Initial boot cost is 30s -- and when you only want to run lint on one file, or open your editor for the first time... it's a rough time.
January 17, 2025 at 11:55 PM
Reposted by David Gonzalez
Nice!

Wavesurfer.js is an #opensource audio visualization library for creating interactive, customizable waveforms.

wavesurfer.xyz

github.com/katspaugh/wa...

#music #audio #opensource #TypeScript
GitHub - katspaugh/wavesurfer.js: Audio waveform player
Audio waveform player. Contribute to katspaugh/wavesurfer.js development by creating an account on GitHub.
github.com
January 16, 2025 at 3:45 AM
Reposted by David Gonzalez
I made a fun little project this past week: formatly 🧼. It detects whatever formatter -biome, deno fmt, dprint, or Prettier- a project is using and formats files with it.

Hoping to grow this to be used in any project that writes source code for users.

github.com/JoshuaKGoldb...
GitHub - JoshuaKGoldberg/formatly: Formats your code with whatever formatter your project is already using. 🧼
Formats your code with whatever formatter your project is already using. 🧼 - JoshuaKGoldberg/formatly
github.com
January 12, 2025 at 11:53 PM