I am a Front End dev and looking for ways to transition away from JS using F# or some other language. I know you can do SSR well with any language basically, but SSG and CSR and ISSG and all that doesn't seem to be well supported by other non-JS languages. If you know any in F# that can do more than just SSR easily let me know because all those features is why I stay with Next.js in regular JS. 😵💫
Hm... I think you are looking at everything from a very JS / SPA centric approach. In the end basically all general purpose languages can do anything the other languages / frameworks do. * SSR - Server Side Rendering - Server renders the HTML and returns (F# can do this, NestJS can do this) * SSG - Static Site Generation - This is literally SSR but you've pre-cached the results. So.... there's really no difference except you've pre-cached. If you can do SSR you can do SSG. * ISSG - Incremental Static Site Generation - This is literally SSG with SSR mixed in. So again if you can do SSR you can do this as well. The only one here where JS has a clear edge is CSR (Client-Side Rendering) as JS is the language browsers speak. So for that stuff JS will have an edge. That said you can always use something like Blazor to get F# to render to wasm and run in browser or Fable which will transpile F# to JS. I would also point out that all CSR / JS frameworks eventually render down to HTML - so you can really get ab 80-90% of any kind of rendering you want with just HTML / CSS w/o needing a heavy-weight JS lib. TBH I might recommend you read Hypermedia Systems. It's about HTMX but I think gives a good explanation of core web fundamentals which might provide a different perspective on how to build frontends with less JS - even if you don't choose HTMX as the tool for it.
I am a Front End dev and looking for ways to transition away from JS using F# or some other language.
I know you can do SSR well with any language basically, but SSG and CSR and ISSG and all that doesn't seem to be well supported by other non-JS languages.
If you know any in F# that can do more than just SSR easily let me know because all those features is why I stay with Next.js in regular JS. 😵💫
Hm... I think you are looking at everything from a very JS / SPA centric approach.
In the end basically all general purpose languages can do anything the other languages / frameworks do.
* SSR - Server Side Rendering - Server renders the HTML and returns (F# can do this, NestJS can do this)
* SSG - Static Site Generation - This is literally SSR but you've pre-cached the results. So.... there's really no difference except you've pre-cached. If you can do SSR you can do SSG.
* ISSG - Incremental Static Site Generation - This is literally SSG with SSR mixed in. So again if you can do SSR you can do this as well.
The only one here where JS has a clear edge is CSR (Client-Side Rendering) as JS is the language browsers speak. So for that stuff JS will have an edge. That said you can always use something like Blazor to get F# to render to wasm and run in browser or Fable which will transpile F# to JS.
I would also point out that all CSR / JS frameworks eventually render down to HTML - so you can really get ab 80-90% of any kind of rendering you want with just HTML / CSS w/o needing a heavy-weight JS lib.
TBH I might recommend you read Hypermedia Systems. It's about HTMX but I think gives a good explanation of core web fundamentals which might provide a different perspective on how to build frontends with less JS - even if you don't choose HTMX as the tool for it.