News for hackers. Stuff that matters.
Re:Is htmx Just Another JavaScript Framework? by mythz on Thursday January 11, 2024 @10:17AM (#38953317)
Reasons why I no longer prefer SPA's:

  - Build tools are complex
  - Large FX's have 100's of npm dependencies
  - Every SPA I've created has suffered from bitrot overtime, including:
  - Often breaking changes on upgrade, incompatibility between package versions
  - Dependencies/tools/fxs often abandoned, rewritten, replaced, etc
  - Constantly wasting time working around issues
  - Doesn't scale, the larger the App, the slower initial load and slower the FCP
  - Heavy client state and need to manage client routing
I now prefer using #NoBuild [1] ESM builds of progressive JS FX's for adding behavior to static rendered content where each page only loads the JS it needs, which ends up being much simpler [2] and resolves these issues I used to have with SPAs. Blazor with static rendering and Enhanced Navigation is even nicer which gives SPA-like navigation responsiveness without SPA-like complexity [3].

[1] https://world.hey.com/dhh/you-can-t-get-faster-than-no-build...

[2] https://servicestack.net/posts/javascript

[3] https://servicestack.net/posts/net8-best-blazor

There are no comments on this comment yet.