Post #2019169
2026-05-04 12:16 UTC
@jimniels I came across this post on HN.
it's a nice instinct to try to be js-free, but then you're just using js to manipulate your history, which is surely far more blasphemous than a sprinkling of js to show/hide a menu. Especially when you're doing a full nav for this.
I beg you to check out Datastar. It's precisely what you're looking for. It's more powerful than htmx + alpine js, and smaller than both. You could just have a few declarative html attributes that show/hide the menu.
Replies (1)
-
@spartanatreyu@mastodon.social 2026-05-05 07:03
@nickchomey @jimniels Things like datastar / livewire / etc... are always the wrong solution to the wrong problem. They don't simplify things, they hide complexity behind magic (even more hidden complexity). Don't couple your user's UI to schrodinger's server connection to create a more brittle ``, just use the `` instead. But since this is a menu, you **should** be using a `` and progressively enhance with `aria-expanded`. You are looking at accessibility too right?