Live data from Hacker News

Moving from React to htmx

htmx.org

111–120 of 326 posts

Re: Moving from React to htmx

#111
I was expecting something that would blow me away... but honestly that UI is not super sophisticated. You could solve that with vanilla or jQuery. Obviously React (or any of the modern libs/frameworks) would be overkill for that.

IMO this video reinforces the idea that for personally simple stuff I'd rather just use jQuery (or rather CashJS) or even vanilla.

Re: Moving from React to htmx

#112

What is the best framework to build a high performance web application on? Specifically for building a UI to work with large sets of tabular data similar to a spreadsheet, e.g thousands of rows. Is Htmx up for this task?

Check AG Grid

Re: Moving from React to htmx

#113
post #4

Earlier quoted context omitted.

Speed is the big one for me. 2-6+ seconds is insanity for anything.

I hear you, but YouTube takes 6+ seconds for me to load and it does not seem to hold them back. For most, not all, optimizing page load time is time probably best spent elsewhere. This is is no way to impugn htmx, because with htmx you seem to kill many birds with one stone.

Details matter, as they learned when making things faster made their metrics slower - https://blog.chriszacharias.com/page-weight-matters

Re: Moving from React to htmx

#114

serve side rendering is ideal, but at the end of the day what matters these days is developer productivity. a better question is how long it takes to make something like gmail with htmx vs. say react. you might say most apps are not gmail, and you'd be correct. so then you say, ok what about something like wikipedia? easy enough. then you start adding all of this javascript and it becomes a mess.

Use the right tool for the job. Obviously Gmail is a much better fit for React/Vue/etc than HTMX. Gmail is the perfect use case for an SPA but most web apps don't need to be an SPA.

Re: Moving from React to htmx

#115
Speeding up the build could be done in other ways, were they using esbuild or something fast previously? Probably not.

The memory usage saving is really not a big deal, load up your favourite news web page and look at the memory it chews up in comparison.

As for the preference implied for python over js, that's fine, but the choice is not binary, typescript is my preference for a React project, for example.

Reduction in LOC is slightly misleading, JSX creates a lot of lines.

It would be interesting to see a proper write up on the data React couldn't handle.

Re: Moving from React to htmx

#116

I'm just so burnt out with new things. How do I combat such burnout? I really don't care about 'Htmx', I think barely any apps need much beyond what was available in ~2006 in terms of web tech. I just feel tired knowing that moving from React to Htmx is an option. Yet another option which will very possibly bring zero commercial value (although it might be a nicer dev experience I guess) to any project I ever work on…

[deleted]

Re: Moving from React to htmx

#117

I'm just so burnt out with new things. How do I combat such burnout? I really don't care about 'Htmx', I think barely any apps need much beyond what was available in ~2006 in terms of web tech. I just feel tired knowing that moving from React to Htmx is an option. Yet another option which will very possibly bring zero commercial value (although it might be a nicer dev experience I guess) to any project I ever work on…

Why not just limit your perusal of the new stuff? It's interesting enough if you're in the game to keep apprised, from a 10,000 ft pov, of what's around. A delimited once-a-day/week/whatever browse fulfils that. But stop there. Let all your further dives into new tech be driven purely by actual needs/uses (career or business or hobby etc).

The solution to the Paradox of Choice is to opt out. Human minds aren't soul-stuff magic - they're evolved systems whose history hasn't equipped them to deal fluently with unlimited choices. That's just physical reality, so we need to comport with it, not with the blandishments of the virtual business/tech world.

In many domains of contemporary life, one way to be free (and reduce anxiety) is to use volitional attention to restrict the range of choices we're presented with.

Re: Moving from React to htmx

#119
post #67

Earlier quoted context omitted.

I think anywhere you introduce more complexity, more ways for things to interact, it's inherently less secure without the additional work checking for both the App + the API being secure on their own.

There's no such thing as a secure "app". Only the API needs to be secure. That's more straightforward when your API looks like REST/RPC calls rather than "renders html templates to a string".

> Only the API needs to be secure.

If users type passwords, sensitive data, anything into the frontend then any javascript, plugins etc pulled in by that page is an attack vector.

Post reply on HN