-
-
Notifications
You must be signed in to change notification settings - Fork 122
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Required Properties support by default #563
Comments
Also, just so you know, AutoFac looks at the attributes that C# decorates classes and properties with so that no extra properties or attributes are necessary. It doesn't set all properties. Just the required ones which is really nice. |
@TonyValenti got it |
Any idea when this will be released? |
…g constuctor when injecting the properties for #563
Here is the example how to configure the |
Hi @dadhi , |
@TonyValenti For the next version v5.4.0 you need to specify the support for the var c = new Container(rules => rules.With(propertiesAndFields: PropertiesAndFields.RequiredProperties())); I still need to work out the performance considerations to make it the default rule. |
The issue for the custom rule support #571 |
Discussed in #562
Originally posted by TonyValenti March 16, 2023
AutoFac recently implemented required properties injection and it is awesome!
https://autofac.readthedocs.io/en/latest/register/prop-method-injection.html#required-properties
This eliminates a ton of boilerplate constructor code, especially where inheritance is involved.
Dryloc should follow suit.
The text was updated successfully, but these errors were encountered: