Make settings required
Last updated
Was this helpful?
Last updated
Was this helpful?
Requires: .
By default all settings are optional; that is, absence of relevant data in the results in default values during and does not produce errors.
Some parts of configuration may be crucial to the application to the point that it's pointless to start without them being initialized. These fields and properties should be annotated with [Required]
attribute:
Default behavior can be inverted in the scope of a type with [RequiredByDefault]
attribute. Individual fields and properties can then be made optional with [Optional]
attribute: