Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

It is far beyond just using C# to javascript. That would just maintain the same way of thinking.

The functional approach uses entire different structure. It isn't just a transpiler.



It's not really different. If you use .razor files it hides the way state mutation works so it superficially looks more imperative (I guess so it isn't scary to people who are used to server rendered razor templates in asp.net) but it's basically the same as MVU/react/elmish/whatever in f#/fable just without explicit update messages.

You can trivially build something that looks exactly like elm/elmish on top of blazor if you just organize your code that way.

Also, I like fable but you have to be careful about what .net features you use because it's transpiled and the standard library is reimplemented (there's lots of stuff that hasn't been implemented). Blazor has better compatibility and you can use pretty much anything in .net and even native code that has been compiled to WASM.

So 1) there's no good reason to abandon blazor for something more like fable in terms of being transpiled to javascript, since wasm will only be more mature, and 2) if you want something that looks more functional like f# with elmish you can easily get that on top of blazor.

(There is even something similar to fable/elmish on top of blazor for f# (Bolero) but you could do the same thing in c# too).




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: