3 ms·
I feel this way about F#. It's so much better than C#, I'm constantly missing things from it when in C#. I go back to C# and try to explain the missing features
by JackMorgan 2y ago
I feel this way about F#. It's so much better than C#, I'm constantly missing things from it when in C#. I go back to C# and try to explain the missing features but just get blank stares, because it's hard to imagine a feature you've never seen before.
C# is a fine server-side language, but to be honest it's only gotten there since .NET Core worked on Linux. I still have to work sometimes on crusty old framework projects that constantly break. Every week these teams are chasing down some MSBuild version error, or are dealing with an issue caused by the WCF SOAP endpoints, or some home grown ORM crap because EF was absolutely terrible until recently. So many build errors because the code runs on a windows server that just got patched and for some reason the code won't run.
There's a real toxic cultural effect too. I know plenty of .NET projects that just collapsed because they followed the crowd and designed a complete mess of lasagna. I'm talking 10+ layers just to get a record out of the database and sent to an API. So many classes like "ManagerRepositoryFactoryFactoryImpl". So much indirection with event pipelines and listeners and DI. I've seen an audience give a standing applause to a C# talk where the main point was "more than one function in a file causes bugs, so every function should be in it's own file".
There's so many niche cultures that celebrate what I'd call "bad code". And it's hard to buck that trend when a big chunk of your hiring pool has bought into a terrible design philosophy. Not everyone, plenty are wise and see it as nonsense, but plenty have bought into some really weird ideas, see it not work, but then blame the implementation not the philosophy. Then they move along to the next project, brimming with holy zeal to "fix" it with design patterns and event sourcing.
But yeah, today, coming into it fresh, .NET Core is pretty rad. I manage three client projects on it, and it's pretty great. It's really smooth, builds great, is fast enough for CRUD, EF is decent and I can write raw SQL for the 20% of queries that need it. I can autogenerate swagger docs with swashbuckle, then autogenerate my typescript API consumer from that. I've got my code building and running in Linux docker containers and it all just works and it's fast enough for what I need.
But it's forgetting a lot of history and culture to assume it was always this good. It definitely was the worst back in 2003-2014. Keep in mind it used to be closed source and you had to pay through the nose for Visual Studio just to build anything at all! IIS and VSS from 2008 still give me nightmares. Up until about 2020 I recommended people use other tools if they were starting a new project. Today, it's my first recommendation for a backend.
(Also I think Visual Studio still is really lacking in features, so I use Rider instead and it's awesome. But to each their own)