Skip to content

Instantly share code, notes, and snippets.

@m-malkowski
Created June 18, 2018 08:51
Show Gist options
  • Select an option

  • Save m-malkowski/58ac54cfbedad83e2712bc446281aa70 to your computer and use it in GitHub Desktop.

Select an option

Save m-malkowski/58ac54cfbedad83e2712bc446281aa70 to your computer and use it in GitHub Desktop.
Working with built-in dependency injection of ASP .NET Core - Attributes
[AttributeUsage(AttributeTargets.Class, AllowMultiple = false)]
public class InjectableTransientAttribute : Attribute
{
}
[AttributeUsage(AttributeTargets.Class, AllowMultiple = false)]
public class InjectableScopedAttribute : Attribute
{
}
[AttributeUsage(AttributeTargets.Class, AllowMultiple = false)]
public class InjectableSingletonAttribute : Attribute
{
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment