Live data from Hacker News

A whirlwind tour of object-oriented code in F# (2012)

fsharpforfunandprofit.com

21–30 of 130 posts

Re: A whirlwind tour of object-oriented code in F# (2012)

#21
post #8

The problem is F# doesn't get enough resources internally at Microsoft. How many times has VS shipped missing the latest version of F# tools? In terms of community, it's tiny. If I want to do functional programming, F#/.NET isn't the strongest option. I have several books on F# and as much as I'd like to learn/use it beyond toying around, I can't help but feel like all it's worth using for is tinkering (outside of th…

What is the strongest option for functional programming then? I love Clojure as a language but it's almost impossible to find decent jobs with it in my area.

Re: A whirlwind tour of object-oriented code in F# (2012)

#22

Years ago I was working a miserable job writing boilerplate template code where I had to sub in variables based on certain conditions, it was using a very bland language to look up data from our database and format the output. I wasn't allowed to download any software onto my work computer despite having a technical background. So what I did instead to make my life easier was write F# to create a kind of DSL and crea…

Reads like an opening of a dystopian novel!

Re: A whirlwind tour of object-oriented code in F# (2012)

#23

For all the love Microsoft has been getting these days, I still don’t get how I’m supposed to write C# or F# without Visual Studio and Windows. Am I missing something? VSCode doesn’t support these languages, right? I’m a person who spent a long time trying to write Java in Vim, but switched to IntelliJ and wouldn’t want to write C#/F# without some comparable IDE.

I actually find the F# experience using VS Code + Ionide plugin in a Mac beyond what I’d ever thought was possible without something like a full blown ide.

The maintainers of Ionide also just got Microsoft $$ so that’s even better news.

But working with F# and it’s strong types while at the same being able to write something similar to Python should be a giant selling point to anyone.

If you’re on a Mac or linux just download the .net core sdk and you’re ready to go

Re: A whirlwind tour of object-oriented code in F# (2012)

#24
It's a pity the tooling is comparatively immature, with F# (or at least that was my experience last time I tried to develop with it). I think Rider is getting there, though.

To go into more detail, the initial implementation in Rider was limited to not much more than syntax highlighting. Inspections were fairly limited, ASP.NET MVC integration was not as featureful.

On the C# side, it's much more developed and refined. Within Rider, it's obviously been the main focus so I suppose it's only natural it's received more polish.

Re: A whirlwind tour of object-oriented code in F# (2012)

#25

For all the love Microsoft has been getting these days, I still don’t get how I’m supposed to write C# or F# without Visual Studio and Windows. Am I missing something? VSCode doesn’t support these languages, right? I’m a person who spent a long time trying to write Java in Vim, but switched to IntelliJ and wouldn’t want to write C#/F# without some comparable IDE.

>I’m a person who spent a long time trying to write Java in Vim, but switched to IntelliJ and wouldn’t want to write C#/F# without some comparable IDE.

Rider is the comparative option for you. I wouldn't waste much time on VS Code, personally.

Re: A whirlwind tour of object-oriented code in F# (2012)

#26

For all the love Microsoft has been getting these days, I still don’t get how I’m supposed to write C# or F# without Visual Studio and Windows. Am I missing something? VSCode doesn’t support these languages, right? I’m a person who spent a long time trying to write Java in Vim, but switched to IntelliJ and wouldn’t want to write C#/F# without some comparable IDE.

You can use Rider which is a very good crossplatform JetBrains IDE. I found it very fast too (I use it on Fedora in my laptop)

Re: A whirlwind tour of object-oriented code in F# (2012)

#27

For all the love Microsoft has been getting these days, I still don’t get how I’m supposed to write C# or F# without Visual Studio and Windows. Am I missing something? VSCode doesn’t support these languages, right? I’m a person who spent a long time trying to write Java in Vim, but switched to IntelliJ and wouldn’t want to write C#/F# without some comparable IDE.

F# in VS Code: https://docs.microsoft.com/en-us/dotnet/fsharp/get-started/g... F# in .NET CLI: https://docs.microsoft.com/en-us/dotnet/fsharp/get-started/g... C# in VS Code: https://docs.microsoft.com/en-us/dotnet/core/tutorials/with-... Supported Linux versions: https://docs.microsoft.com/en-us/dotnet/core/linux-prerequis... Supported macOS versions: https://docs.microsoft.com/en-us/dotnet/core/macos-prerequis... Ri…

Thank you for these links. I will look at them! But I am wondering qualitatively, along the lines of whb07’s sibling answer: is the experience good? Is it as good as on Visual Studio?

Re: A whirlwind tour of object-oriented code in F# (2012)

#29
post #28

If you want to try F#, here's the full F# compiler in the browser run using WebAssembly. Very fun to play with: https://tryfsharp.fsbolero.io/

And it also compiles to Javascript: https://fable.io/repl/

You can browse through some sample apps using the side bar on the left.

Re: A whirlwind tour of object-oriented code in F# (2012)

#30
I just bought Scott's book on Railway Oriented Domain Driven Design. So far so good. I am the domain expert though, so no revelation there.

The modeling of state machines using types and functions is pretty revolutionary to me for where I'm currently at development skill wise. Everything just seems so clean and elegant.

Post reply on HN