Hacker News new | ask | show | jobs
by typicaljoe 5396 days ago
I find F# very tempting as a gateway into .NET. Anyone used it with MVC?
2 comments

Yup, I even wrote a framework to convert F# to javascript which allowed me to create a new (really powerful) validation provider for MVC. Sadly I haven't had a real world project that fit it well, so it's kind of gone by the wayside.

It's fairly straight forward to use with MVC, though it's less than ideal. You basically need to have a C# MVC project that referneces your F# projects (these would contain your controllers etc.)

It can be used with MVC, but the problem is MVC is still C# centric - as in the scaffolding bits that it generates are C# (or VB).

There's also the question of Razor supporting F#, which is not yet there. I remember somebody spiking some code for that, not sure if it's usable.

You can still write all your controllers in F#; but if your front-end is C#(razor), and if your data access is in L2S or EF, then F# feels like added baggage. Still could be useful in some occasions.