News for hackers. Stuff that matters.
Re:XMLUI by Too on Monday July 21, 2025 @03:39AM (#44632673)
So instead of ’const tubeStations = useDatasource()’ we now type ’<DataSource id=”tubeStations” />’ and anything beyond this basic example is left as exercise for the reader.

Doesn’t seem like a big improvement? In fact the opposite. Sure, React’s stateful hooks mixing in a semi-declarative mode of programming in otherwise imperative code isn’t exactly intuitive, but the flexibility and familiarity you get from having full JavaScript at your fingertips is worth everything. Hands up anyone who want to learn how to make a for-loop with filter+map in xml syntax. Didn’t think so.

If you want to fix react what you should do instead is keep jsx and give stateful hooks a dedicated section that can’t be mixed up in rendering code.

Re:XMLUI by ricardobeat on Monday July 21, 2025 @09:48AM (#44635062)
You're forgetting the state management required to link the components. Here's a take (by Claude) on what it would look like, even if you ignore the entire `useDataSource` implementation it's an entirely different beast:

https://gist.github.com/ricardobeat/8aedb9c6d3a1b0bfaba9cc55...

Re:XMLUI by judell on Monday July 21, 2025 @11:25AM (#44636311)
> exercise for the reader

The demo app shows a bunch of patterns. https://docs.xmlui.org/tutorial-01