Injecting a service in a view
In the ASP.NET MVC 6, you can now use the @inject keyword. This allows you to inject a service (class) into your view. This class must be public, non-nested and non-abstract. The @inject needs 2 “parameters” in order to work. @inject [name of your class] [variable name that can be used in your view] My […]
Read More →