Update options.md (#23765)
parent
40eda6978c
commit
c2a13ad315
|
@ -190,7 +190,7 @@ The following class implements <xref:Microsoft.Extensions.Options.IValidateOptio
|
||||||
|
|
||||||
`IValidateOptions` enables moving the validation code out of `StartUp` and into a class.
|
`IValidateOptions` enables moving the validation code out of `StartUp` and into a class.
|
||||||
|
|
||||||
Using the preceding code, validation is enabled in `Startup.ConfigureServices` with the following code:
|
Using the preceding code, validation is enabled in *Program.cs* with the following code:
|
||||||
|
|
||||||
[!code-csharp[](options/samples/6.x/OptionsValidationSample/Program.cs?name=snippet_xm)]
|
[!code-csharp[](options/samples/6.x/OptionsValidationSample/Program.cs?name=snippet_xm)]
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue