DI is an important patter that we normally use in .NET applications. DI help us to inject services and other kind of objects into blazor components.
Refer this link https://blazor-tutorial.net/dependency-injection