Search code examples
asp.net-corereferenceframeworks

Add AspNetCoreApp to referencing Framework


I have a .NetCore Project, and want to use Kestrel webserver. To do so, I need to add the aspNetCore framework. How can I do this, ans in which file? Thanks, Thomas.

I looked at the *.csproj file, but there is nor target framework in it. enter image description here


Solution

  • add to <projectname>.csproj
    ....
      <ItemGroup>
          <!-- Add ASP CORE -->
          <FrameworkReference Include="Microsoft.AspNetCore.App" />
      </ItemGroup>
    

    That's it.