Live data from Hacker News

.NET 10

devblogs.microsoft.com

251–260 of 605 posts

Re: .NET 10

#251

Earlier quoted context omitted.

Recommended by whom? I've been doing .NET for 23 years (since the first beta) and I've never paid for a single library in any commercial project I've been part of.

Moq, lots of PDF libraries, Avalonia, Automapper, MediatR, MassTransit,Telerik stuff,etc. I'm not inherently against it, we have a problem with opensource being asymmetrically underfunded and if people going commercial is the cost perhaps we've failed.

There are a few non-paid PDF libraries, but that is the biggest pain point in .NET, anytime you need advanced features for PDF, you're better off paying for a license (it's just insanely expensive unless you're a large company).

Having worked on some basic parsing of metadata from PDF spec, I would rather pay than have to code something myself. PDF is such a PIA.

Re: .NET 10

#252
post #81
post #47

Earlier quoted context omitted.

As a startup, what is it in for me to switch from Java, Spring Boot, Hibernate, Beam, Flink, Pulsar, Vault, KeyCloak ecosystem to C#.Net? Is the documentation better? Do I get better performance? Is the community larger and more stable?

Vault, Keycloak, Flink are language agnostic or there exist bindings for most popular languages. Documentation is vastly better compared to Java ones, it's like day and night, LINQ is vastly superior to anything that Java offered - but i haven't used java in a very long time. And every time i had to write java it felt like i went backwards in time by 5-10 years. If i remember right Java's webserver beats ASP.NET in p…

> but i haven't used java in a very long time

What was the last Java version you used? There has been a huge momentum in adding new features lately, granted, it is slower than in C# (Java's top priority is backwards compatibility, so it does not have the luxury of shedding old stuff or changing them once they are in), but in the last couple of years it has improved tremendously. The JVM (especially in the garbage collection front) but also the language - half of an ML-style language is there (for example, ADTs and pattern matching), the other half is coming soon!

Re: .NET 10

#253

To me, it's pretty much unbelievable that Microsoft introduces an agent framework while for JSON serializing third-party Newtonsoft is still the go-to. Edit. I was not aware that the gap between System.Text.Json and Newtonsoft narrowed, take my comment with a grain of salt, please!

What's wrong with System.Text.Json?

Last I checked they stubbornly insisted on reinventing the wheel and ignoring everything in System.Runtime.Serialization so you had to redecorate everything with their new attributes. For example https://github.com/dotnet/runtime/issues/29975. So we stuck with Newtonsoft for the time being.

Re: .NET 10

#254
post #2

For us, every .NET upgrade since .NET 5 has gone surprisingly smoothly and reduced CPU/RAM usage by 10–15%. We were even able to downgrade our cloud servers to smaller instances, literally. I wish .NET was more popular among startups, if only C# could get rid of the "enterpisey" stigma.

> I wish .NET was more popular among startups, if only C# could get rid of the "enterpisey" stigma. I tried .NET and liked C# as a language. But even though the language and runtime are now open source, it seemed like a lot of the recommended libraries were still commercially licensed, which was an immediate nope from me. I've never encountered that in any other ecosystem.

Easy to avoid depending on the area; I'd urge you not to be discouraged by the presence of commercial libraries. They aren't as vital as it may seem from the outside. I've been a full-time C# developer since the first open beta and I have only one (1) instance where I used a commercial library. That was 2002 and if we were doing it today, we wouldn't have needed that commercial library. I have never used a commercial C# library other than that one time. We have a tremendous supply of open source libraries in NuGet, just like every other language, and much more functionality built into the standard library than most languages have. We just also have commercial UI libraries and such. That commercial library we used was a docking/tabbing UI library; you can get that from open source packages now (and my later projects do).

Re: .NET 10

#255
post #181

Earlier quoted context omitted.

I'm at a series-C, YC startup. We made a switch from TypeScript to C# two months back. Now we have a team of over a dozen backend engineers working on C# transitioning from TypeScript. 90% are working with C# for the first time. (We are still hiring backend C# engs!) I can say that it has gone waaaaaay smoother than anyone would have thought. This is a decision (language switch) that the team has been putting off for…

So should I learn C# by learning Typescript? Does that make sense?

As much as I think C# at a platform level is a better tool for building backends, you'll get the better bang for the buck learning TypeScript if you don't already know TypeScript.

Then if you have the chance, you'll find C# an easy transition from TypeScript, IME. Learning C# first, on the other hand, will make you a better TS developer, in my opinion, because it will shape your approach to be more diligent about using types. This is something most JS/TS devs do very poorly and at scale, it's very hard to reason about code when it requires digging down several layers to find the actual types/shapes.

"Enterprise" frameworks like Nest.js are much more similar to ASP.NET or Spring Boot than they are to Express, Hono, or Elysia so once having experience with .NET Web APIs (or Spring Boot) will make Nest.js (for example) easier to pick up.

Re: .NET 10

#256
post #250

Earlier quoted context omitted.

>> Yeah, .NET is a truck and React is a bicycle I'm not a car guy but I most certainly a bicycle lover, so I will jump on you and say you often need more than one type of bicycle. Joan commutes to work? she wants a city ebike. Dan rides at the bike park? He wants a DH bike. Randy ride centuries on the weekend on his TDF road bike and Sally rides with her kids on a mountain bike. So yeah, we can pick one bike type and…

Eh, no, you don't hire those employees. You're stretching this analogy in some odd ways.

Well, they clearly all know how to ride bikes, so you offer to hire them to deliver using company bikes as a day job. And let them ride whatever they want on weekends.

The "force everyone to ride it" on the weekend part is where I think the analogy has broken down irreparably. We're talking about cost of ownership of company equipment used during working hours for much more defined tasks. What flavour of bike you enjoy riding on weekends is not relevant.

Programming language are inherently flexible, especially those that aim to be "general purpose". Fine-grained distinction of road bike vs mountain bike apply more to the apps created than the coding tool.

Re: .NET 10

#257

Earlier quoted context omitted.

Recommended by whom? I've been doing .NET for 23 years (since the first beta) and I've never paid for a single library in any commercial project I've been part of.

Moq, lots of PDF libraries, Avalonia, Automapper, MediatR, MassTransit,Telerik stuff,etc. I'm not inherently against it, we have a problem with opensource being asymmetrically underfunded and if people going commercial is the cost perhaps we've failed.

I can confirm that (several years ago at least) free PDF libraries were lacking, and Telerik was always non-free.

However, aren't Moq, Avalonia and MassTransit free software?

As for Automapper and MediatR, their owner changed from a free software license to only an open source one (Reciprocal Public License), but these are probably the simplest libraries of the ones you mentioned and have either been forked (MagicMapper) or have alternatives.

Re: .NET 10

#258

Earlier quoted context omitted.

OpenAPI does support patterns for fields and nullables/non-nullables - that already gets you very far regarding validation. A decently sophisticated generator (which don't exist IMHO) would generate the validation code for your respective language.

True, but you can get all the way to zero duplication if you write it directly and share that code.

[deleted]

Re: .NET 10

#259

Earlier quoted context omitted.

Microsoft is still supporting VB.NET, Windows Forms/WPF, and to a lesser extent VBA. I doubt F# is going away anytime soon.

Supporting as in maintenance mode, at least VB.NET. Thankfully F# is more community driven, but the CLR ecosystem is definitely getting C#-centric in the use of idioms and features from newer C# versions, which increasingly affects F# interop while they catch up.

.NET has always been both the biggest blessing and the biggest curse for F#.

We have access to millions of libraries. I look at BEAM languages and OCaml every once in a while but can’t quite drag myself over there, knowing that in .NET, just as an example, I can choose between a dozen JSON serialisation libraries that have been optimised and tuned comprehensively for decades.

But then, those libraries are also our curse. If you consume them, everything is OO so you either give up on functional purity and start writing imperative F# code, or you have to spend time writing and maintaining a F# idiomatic wrapper around it.

Similarly I was working recently on project to develop a library which was going to have downstream consumers. The problem lent itself really well to domain modelling in F#. But I knew that my downstream users would be C# devs. I could invest the time and write my library as “functional core, imperative shell”. But then I decided that since the interface would be OO anyway, I might as well just write it in C#.

Thankfully what keeps F# going is the wonderful community around it, not Microsoft. I know some people (outside of Microsoft) have worked on a standalone F# compiler but it’s still very early stages. Maybe one day.

Re: .NET 10

#260

Earlier quoted context omitted.

> It's just the amount of money spent on Windows/Microsoft for small companies is rather large, compared to other alternatives that are just as good. This is a complete mis-perception about the modern ecosystem. We have a full team using C# at a series-C, YC startup with every developer on Macs (some on Beelinks and Linux). The team is using a mix of VS Code, Cursor, and Rider. We deploy to Linux container instances…

My last comment, which you referenced... focused not just on C# or .NET.. but the focus of "you need Microsoft" in general.. this includes Windows, SQL Server, etc. Again, my comment is focusing on someone on the outside looking in.. and WHY people end up making decisions away from C# in favour of (something like) Go. I am aware of deploying to Linux containers, etc.

Yes, I am very aware of this and have spent a lot of time/effort trying to dispel some of these myths and mis-understandings through writing.

- TypeScript is like C#: https://typescript-is-like-csharp.chrlschn.dev/

- 6 .NET Myths Dispelled: https://medium.com/dev-genius/6-net-myths-dispelled-celebrat...

- The Case for C# and .NET: https://itnext.io/the-case-for-c-and-net-72ee933da304

Post reply on HN