Sample Asp.Net Core apps with code

TkTech 56 Reputation points
2021-05-06T13:06:15.147+00:00

I want to be more hands on in ASP.Net Core MVC, Web API.

Where can I find good samples of full ASP.NET Core MVC projects ? Looking for code samples which are good on the 'Best Practices and good on architecture front.

Projects in the link below seem little old.
https://www.danylkoweb.com/Blog/where-can-i-find-samples-of-full-aspnet-mvc-projects-HL

Please advise.

Developer technologies | ASP.NET | ASP.NET Core
{count} vote

2 answers

Sort by: Most helpful
  1. Duane Arnold 3,216 Reputation points
    2021-05-06T14:51:00.35+00:00

    @TkTech

    https://en.wikipedia.org/wiki/Separation_of_concerns

    https://learn.microsoft.com/en-us/dotnet/architecture/modern-web-apps-azure/architectural-principles

    https://www.c-sharpcorner.com/UploadFile/56fb14/understanding-separation-of-concern-and-Asp-Net-mvc/

    https://ardalis.com/new-is-glue/

    https://learn.microsoft.com/en-us/archive/msdn-magazine/2016/may/asp-net-writing-clean-code-in-asp-net-core-with-dependency-injection

    Understand what it means about using the Models and keeping the controller thin which also applies to the WebAPI controller.

    https://learn.microsoft.com/en-us/aspnet/mvc/overview/older-versions-1/overview/understanding-models-views-and-controllers-cs

    https://codeburst.io/interfaces-in-c-write-reusable-and-maintainable-code-that-scales-a144ca06b1f7#:~:text=When%20classes%20are%20not%20dependent,known%20as%20loose%2Dcoupling%20architecture.&text=It%20means%20we%20can%20have,class%20that%20implements%20multiple%20interfaces.

    https://deviq.com/terms/kinds-of-models

    https://www.dotnettricks.com/learn/mvc/understanding-viewmodel-in-aspnet-mvc

    https://learn.microsoft.com/en-us/aspnet/web-api/overview/data/using-web-api-with-entity-framework/part-5

    https://www.codeproject.com/Articles/1050468/Data-Transfer-Object-Design-Pattern-in-Csharp

    https://javarevisited.blogspot.com/2013/01/data-access-object-dao-design-pattern-java-tutorial-example.html

    You'll notice there is not a try/catch in any code on the MVC client side or WebAPI service side code including any project being referenced, which is be caught the global exception handling in the MVC and WebAPI projects.

    https://stackify.com/csharp-catch-all-exceptions/

    In Models folder classes suffix, VM = viewmodel and DM = domain model, and info in the links have been implemented in the GitHub solution example.

    https://github.com/darnold924/PublishingCompany

    HTH

    1 person found this answer helpful.

  2. Yogi 351 Reputation points
    2021-05-09T18:08:53.603+00:00

    If you are learning ASP.NET Core then you should start with how MVC works i.e. Model - View - Controller. Only then you can move to individual topics which are - "Model", "View" & "Controller".
    You can start with - https://www.yogihosting.com/category/aspnet-core/ which covers the topic sequentially one by one.

    Next your question is about Web API. It is not difficult at all, Web API does not have a view it is a way for systems to communicate with one another using JSON, XML or gRPC. Start Web API only when you have some proper knowledge about ASP.NET Core MVC.

    Just going to projects beforehand will not be a good solution because you will not understand most of the codes written on the project. I remember, when I started learning dot net core, I want with topics sequentially for a few months time and did not touched any GitHub based projects.

    So I suggest you to learn the topics one by one, sequentially without jumping into very hard projects.

    Happy coding !

    1 person found this answer helpful.

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.