Saturday, 3 July 2021

ConfigurationBuilder does not contain a definition for SetBasePath or AddJsonFile

 Here I am going to explain how to solve below error in dotnet core


   ConfigurationBuilder‘ does not contain a definition for ‘SetBasePath‘ and no accessible extension method ‘SetBasePath’ accepting a first argument of type ‘ConfigurationBuilder’ could be found (are you missing a using directive or an assembly reference?)


 To fix this issue please install below package from nuget

   PM > Install-Package Microsoft.Extensions.Configuration.Json

No comments:

Post a Comment