Extensibility
Add your own configuration sources and providers.
Create a custom source or provider:
- Define a new provider class (see
src/Providers/Interfaces/for guidance). - Extend your configuration loader or builder with additional sources as needed.
- Respect precedence by adding sources in order.
Example sketch:
public static class ConfigurationLoaderExtensions
{
public static ConfigurationLoader AddMySource(this ConfigurationLoader loader, string endpoint)
{
// fetch data from endpoint, add it to the underlying IConfigurationBuilder
// ...
return loader;
}
}