Forget Entity Framework Core! - How to Use Dapper and Strongly Typed IDs

preview_player
Показать описание
To be clear, there's nothing wrong with using Entity Framework Core. In fact, it's the popular choice for CSharp developers! However, EF Core is now how I like to write my own code. It's just personal preference since I like having the SQL queries in front of me when I'm developing my data access patterns.

Dapper, on the other hand, has been great to use! It perfectly fits my needs. When we combine this with Andrew Lock's StronglyTypedId Nuget package, we can get some great repository APIs to work with. But how can we expand upon the suggested way to integrate Strongly Typed IDs from this package with Dapper?

Let's find out!

----

Thanks to Pakt Publishing for sponsoring!

👇👇👇👇
Check out Architecting ASP NET Core Applications:
☝️☝️☝️☝️

----
🔑 Membership & Subscriptions:

🧠 Courses:

🗣️ Social Media & Links:
----

#softwareengineering #software #softwareengineer #softwaredeveloper
Рекомендации по теме
Комментарии
Автор

📌 Check out Architecting ASP NET Core Applications:


💡 Learn how to program in C#:
🧠Deep dive on C#:
🎁Zero to Hero C# Bundle:
💪 Skill up your refactoring:
✉ Subscribe to my free software engineering newsletter:

DevLeader
Автор

Makes me appreciate Entity Frameworks' ValueConverter.

Thanks for the tip on Andrew Lock's StronglyTypedIds NuGet. Save me doing the wrong thing!

hodgenick
Автор

Is that not too much just to avoid EF? For simple select queries, Dapper = EF and you can confirm this in the SQL profiler. I cannot think of how delete and update statements would differ, but let's consider any difference as luxury tax.

IbrahimKwakuDuah