
Why you should join the .NET Core and ASP.NET Core train - magnusdeus123
https://codingblast.com/asp-net-core-train/
======
bob1029
We've hopped on the AspNetCore train a few weeks ago and its been a blast ever
since. Just having working Swagger API documentation generation OOTB has been
worth it for us.

It has the perfect storm of REST API & SPA web app hosting framework features
in my mind:

\- Annotation and convention based controllers. Binding of headers, body, and
query params is so damn easy now.

\- Annotation-based Swagger API documentation. It just works if you follow the
directions. No need to define metadata classes or any other nonsense. Response
types, content types, headers, required properties, etc - its all annotations
and its all easy.

\- Much better hosting of static content. We love how easy it is to build out
a RiotJS SPA web app and backing RESTful JSON API service in one quick stack.

\- Flexibility with HTTP hosting: HttpSys, IIS, Kestrel, Roll Your Own, etc.

\- Pipeline and extension items are very easy to write now. We actually found
it easier and faster to just hand-roll our token authentication pipeline item
than to configure an existing provider.

\- DI is some intersection of magical and simple. Microsoft's built-in DI
provider kicks ass.

\- Leverages open-source libraries where obviously appropriate by default.
E.g. Newtonsoft.Json as it's the best JSON serializer ever written for .NET
(or any language for that matter IMO).

\- Can host on Windows directly through full 4.6.x framework for access to
DirectoryServices and Drawing or host on top of dot net core for cross
platform (sacrificing windows-specific capabilities).

\- Windows service hosting features built-in (used to have to resort to
TopShelf).

I had to hack in a few things that we liked from the Nancy project (e.g.
automatic URLACL setup for HttpSys hosting), but these were very minor QOL
items.

I think that every .NET/C# shop should take a VERY HARD look at this stack for
any new development. Keep in mind that even though cross platform is marketed
as a large part of this, you can reap 100% of the benefits on full 4.6
framework if you still need to operate in that domain.

~~~
mustardo
Sounds like stuff we have had on the JVM (without MS lock in) since ages ago
[http://www.dropwizard.io/1.2.0/docs/getting-
started.html](http://www.dropwizard.io/1.2.0/docs/getting-started.html) And if
you want terser code [https://kotlinlang.org](https://kotlinlang.org)

~~~
manigandham
It's a very nicely integrated stack though, and there's no MS lock-in anymore:
it's all open-source, you can use VSCode or 3rd-party IDEs to code, and you
can run it on Linux.

------
matrix
Lots of good points, but one thing still keeps me off this particular train:

.NET does not (yet?) have the same level of availability of high quality free
libraries that other major platforms do. Things like image processing,
database DSLs, etc. I think this is in part because Microsoft provides such a
comprehensive stack that it kind of discourages the kind of diversity that
leads to the proliferation of libraries.

~~~
rightos
Their NuGet ecosystem is extremely rich. For example, see
[https://www.nuget.org/packages?q=image+processing](https://www.nuget.org/packages?q=image+processing)

My experience is that LINQ pretty much beats every other way of interacting
with a database I've ever seen.

Core is likely a more restrictive right now - EF Core for example is still in
a very weak state, but things are improving and in a few versions I fully
expect it to be a solid product.

~~~
ajryan
LINQ to SQL is pretty poor in my opinion, plus it's no longer maintained and
bugs aren't fixed[0].

[0]: [http://www.aidanjryan.com/blog/2012/08/25/sqlmetal-bug-
with-...](http://www.aidanjryan.com/blog/2012/08/25/sqlmetal-bug-with-multi-
rowset-stored-procedures/)

~~~
barake
Entity Framework replaced LINQ to SQL years ago - it’s had multiple major
revisions, and two major revs of the .NET Core version.

The initial version in 2008 was a total mess. It wasn’t until a few years
later that the XML definition and code generation junk was removed and it
became useable.

------
partycoder
.NET documentation used to be top quality, but not anymore. Quality of MSDN
articles has declined a lot, going from full, explicit documentation with
examples, to just placeholders in many cases.

PS: criticism of MS or .NET in HN even in reasonable terms is guaranteed -6
karma. But I have karma to spend.

~~~
cjsuk
You get downvoted to hell if you post something negative about MSFT after
around 17:00 UTC. It’s open season between 09:00-17:00 UTC because they’re all
in bed or commuting.

Incidentally I agree with you although MSDN has been difficult to find the
content in for a few years as the auto generated stuff takes precedence.

~~~
partycoder
I would have like 100 additional karma or more if it wasn't for MS related
downvotes.

update: Downvoting started already.

------
yawgmoth
One of the things myself and others maintain about Python's Flask is that it's
very easy to get up and running. I think ASP.NET Core really has nailed that
same sort of streamlined approach. It's less confusing where things plug in
and are extendable vs ASP.NET MVC (which I've had the fortune of using since
version 3). The _idioms_ make a lot more sense than they used to -- and it's
great to see ASP.NET Core idioms expand to other .NET web technologies (e.g.
Giraffe).

------
sorrymate
.NET Core feels very much simplified and has a lot of really wonderful Front
End templates, specifically JavaScriptServices for their React + Redux, Vue,
and Angular starter projects. They feel very much like a Node and React +
Redux project but with a C# backend and TypeScript. I've found it to be really
enjoyable having a type checker, server side rendering, webpack, and a great
deployment story. All out of the box.

You can see an example of something similar here: [https://aspnet-
core.azurewebsites.net/](https://aspnet-core.azurewebsites.net/) and
[https://github.com/kriasoft/aspnet-starter-
kit](https://github.com/kriasoft/aspnet-starter-kit)

------
jchannon
Check out Botwin for a sleeker HTTP experience on top of ASP.NET Core pipeline
[https://github.com/jchannon/Botwin](https://github.com/jchannon/Botwin)

------
eptakilo
I'm a junior dev and I have been meaning to master a framework really well. I
really like the concept of .net core, I have decided to stick with it. But the
documentation is scattered, it doesn't feel consistent.

I wish they made that documentation as pleasant and well put together as
Django's documentation.

As a junior dev good docs are the biggest thing for me.

~~~
pdwetz
It's been a constantly moving target for the last two years. In theory, it
should be getting more stable now with v2 of Core and hopefully all the docs
and various tutorials/blogs/videos/etc will follow suit over the coming
months. In the meantime, you'll probably want to filter out anything prior to
2017.

------
rocqua
* .NET Standard is a set of APIs that all .NET platforms have to implement. This unifies the .NET platforms and prevents future fragmentation.

* .NET Standard 2.0 is implemented by .NET Framework, .NET Core, and Xamarin. For .NET Core, this added many of the existing APIs that have been requested.

This seems to support the narrative that windows is really fickle in what is
'the thing we are definitely going to support from now on'.

~~~
manigandham
How so exactly? If anything it's the opposite. The .NET Full Framework is not
going anywhere, it'll be supported for a very long time from now.

~~~
rocqua
I recall the criticism from yesterday's comments regarding the dropping of
windows phone. There was a thread that harped pretty hard on the fragmentation
of the Microsoft frameworks.

I personally have no experience with any of this, so am just going of second
hand information.

------
he0001
The .net core platform is miles better than the old .net platform, so for
everyone used to the old one, that's a major improvement. But it's still not
good enough platform compared to many others and not interesting enough in
others cases like compared to elixir.

------
RickJWag
I'm a long-time Java programmer, but I have to admit that .NET Core
development is fun.

I like it best on RHEL, or better yet on OpenShift for instant Kubernetes
goodness.

The Java guys better up their game, pronto. .NET Core 2.0 is capable, miles
ahead of 1.0. If 3.0 jumps that much, it'll be a compelling platform.

------
transverse
You should definitely like if you want telemetry auto-reported to Microsoft
for every app you make! It doesn't get any better, folks. You don't even have
to consent for it. See
[https://news.ycombinator.com/item?id=15439001](https://news.ycombinator.com/item?id=15439001)

~~~
romanovcode
1\. It's the CLI tool that is spying, not the binaries you are generating.

2\. `set DOTNET_CLI_TELEMETRY_OPTOUT=true` to disable spying.

