Fellow Haskeller here. On the Haskell side, we have tools like GHCJS, reflex and miso to write client-side web applications that compiles to JS (and wasm, in the future). Reflex in particular uses FRP style of programming.
If I were to move over to F#,
what would be my framework/library options (as someone familiar with FRP)?
is F# client-side web development supported without gotchas on Linux?
are there any real-world web applications written in F# (both backend and frontend)?
The answers to these questions would help me evaluate if it would be worth trying out F# for writing full-stack web apps.
I’ve developed https://www.forcyclistsbycyclists.com using end to end F# making use of the SAFE stack. I’ve mostly developed it on Mac OS with a little work on Linux. Had no issues at all on the former and not aware of problems on the latter. I generally use a mixture of Code with the Ionide plugin and Rider.
I talked about it a little at F# conf 2020 here:
The production environment currently runs on Azure and uses a mix of App Service for Containers, Service Bus, Functions, SQL Server and a few other bits and pieces. I have a dev environment running in AWS on ECS, Fargate, Lambda, SQS and Postgres (and a few other bits and pieces).
The whole system is in F# including Infrastructure as Code where on Azure I’m using Farmer and on AWS Pulumi.
When I gave the talk I think I claimed it was the most productive web dev environment I’d experienced and I continue to maintain that - its been a pleasure to grow, refactor and add to. I’ve had the odd transpiling glitch from Fable but in terms of issues thats it.
If you use a lot of external JS packages you should be prepared to do a little work to get them into Fable - though with Fable 3 I believe that is getting easier.
Happy to try and answer any specific questions.
Thanks to Reed Copsey over on Twitter for sending me here.
The use of F# to address the complexity at the heart of this application clearly demonstrates a sweet spot for the language within enterprise software, namely algorithmically complex analysis of large data sets. My experience has been a very positive one. In particular:
Units of measure The industry I work in is littered with units. The equations I implemented (often of a geometric nature) dealt with units of time, power and energy. Having the type system verify the correctness of the units of the inputs and outputs of functions is a huge time saver, both in terms of testing and reading/understanding the code. It eradicates a whole class of errors that previous systems were prone to.