You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Dec 18, 2018. It is now read-only.
Regarding ConfigurationBinder.cs, it would be nice if the IConfiguration object was provided to the model. Then we would be able to access data even if we didn't add a property for it. I propose, if the model has a IConfiguration property named "Configuration", then it's setter is invoked. The following would go after line 173 and line 198.
addMethod.Invoke(collection, new[] { item });
// If the model has a property named Configuration of type IConfiguration, pass the current configuration focus to the model.
var configProp = itemType.GetTypeInfo().GetDeclaredProperty("Configuration");
if (configProp != null && configProp.SetMethod != null && configProp.PropertyType == typeof(Microsoft.Framework.Configuration.IConfiguration)) {
configProp.SetMethod.Invoke(item, new object[] { configurationSection.Value });
}