天天看點

.net framework引用.net standard的注意點

    1. 注意版本比對
    2. 注意引入.net standard的依賴庫(會報未能加載檔案或程式集的異常)

      在framework中雖然引入了standard的項目,但是其依賴庫沒有自動引入。

      可以參考這篇,用文本編輯器打開

      xxx.csproj

      PropertyGroup

      裡面添加一行代碼:

      <RestoreProjectStyle>PackageReference</RestoreProjectStyle>

    3. 關于這個問題,在其他地方也有提問和解釋:
    4. https://qa.1r1g.com/sf/ask/2987097151/
      https://github.com/dotnet/roslyn/issues/17639
      https://github.com/NuGet/Home/issues/4488      

繼續閱讀