Introduction to Dependency Injection in C#

preview_player
Показать описание
In this video, you're going to learn about code dependencies and how Dependency Injection can improve your C# code. We are not just talking about it, we also write some code and create a sample application using Dependency Injection.

Feel free to ask questions about this video in the comments, give me some feedback and if you like this video, please hit the like button below.

00:00 Introduction
00:30 Video overview
01:02 What is a code dependency?
03:56 Dependency Inversion Principle (DIP)
04:09 How does Dependency Injection work?
04:54 Implement a simple Dependency Injection solution
06:48 Coming up next - DI Frameworks

🔥 C#/.NET Bootcamp: The Fundamentals & more (Code FRIENDS10 for 10% OFF)*

📌 .NET Developer Roadmap

📌 YouTube Playlists:

✅ SUBSCRIBE FOR MORE VIDEOS

🚀 CONNECT & SUPPORT

CREDITS

* Affiliate Link: I earn a small commission at no additional cost
Рекомендации по теме
Комментарии
Автор

Have you ever used Dependency Injection? Do you like it? Let me know what you think!

ClaudioBernasconi
Автор

this is more like a real life example, I'm tired of all the animal and car examples.
short and sweet, now I can understand it from a theory perspective.

thank you!

lnagy
Автор

THIS is the way to introduce dependency injection! I really appreciate showing the traditional method, explaining D.I.P. and implementing the interface. Really helped me understand the basic principals.

RushAustin
Автор

5:44-5:48 had to hear it 3 times and I am like "ooooh, I get it now" thank you very much.

peculiarpeculiar
Автор

I made a drastic change in my career path from Physics Engineering to Software, OpenSource and other sharing cultures in this field stick out from the rest, thanks for your contribution, I'll have mine in years to come, stay afloat :)

sabitkondakc
Автор

I struggled to grasp exactly what the Dependency Inversion principle meant. Thank you for the simple and straightforward explanation ❤

kwenamashamaite
Автор

This is the best explanation I have seen of Dependency Injection.

nickben
Автор

This video should have a minimum of a million views. What an amazing video!

tipster
Автор

An instructor who uses light IDE theme! That's just what I needed.

sushma
Автор

you helped me in a way I can't even explain, thanks a lot!

fabio_davilla
Автор

Just wanted to say how useful this was in explaining a topic I was otherwise struggling to understand! Thank you!

RKO
Автор

Now that is what we call a short but up to the point explanation!! Kudos..!

DotNetCrunch
Автор

Short, sweet and to the point. Thank you

aks
Автор

Ok for some reason no one else could explain this to me and now I understand it and feel like its so simple. Appreciate you

jacobclark
Автор

I know you made this 4 years ago, but as a SE student learning about OOP this is a huge help. Ty!

FANTAZSYREV
Автор

A great example: short, simple yet explaining the essence of DI. Not many are capable of doing this.

KDOERAK
Автор

This is best explanation about D.I I've come across!
Thanks a lot Claudio!

fisnik
Автор

Thank you Claudio Bernasconi, finally got the point about Dependency Injection and I'm grateful about that.

igor
Автор

Can we use DI to pass data between pages. What happens when the use reloads the pages. I know that for Blazor Server for example the connection is lost so the data is lost.

alkishadjinicolaou
Автор

wow thank you soo much you make it soo easy to understand I did not understand in the first time when I watched the video but when I watch it again and focus, I understand it so much

ITGUY-bu