无法构建 Uno Platform UWP 模板项目
Unable to build Uno Platform UWP template project
决定试用 Uno 平台,所以我按照此处的说明进行操作:https://platform.uno/docs/articles/get-started.html
在 VS2019 16.6.4 中使用 Cross-Platform App (Uno Platform) 模板设置新解决方案,然后更新所有 NuGet 包。
不更改一行代码,我无法构建解决方案(或只是 UWP 项目)。选择 UWP/x86 后,出现以下两个构建错误:
Error CS1929 'ILoggerFactory' does not contain a definition for
'AddConsole' and the best extension method overload
'ConsoleLoggerExtensions.AddConsole(ILoggingBuilder,
Action)' requires a receiver of type
'ILoggingBuilder' [PROJECT].Droid, [PROJECT].UWP, [PROJECT].Wasm,
[PROJECT].iOS,
[PROJECT].macOS [PATH] \ [PROJECT].Shared\App.xaml.cs 116 Active
Error CS1061 'App' does not contain a definition for
'InitializeComponent' and no accessible extension method
'InitializeComponent' accepting a first argument of type 'App' could
be found (are you missing a using directive or an assembly
reference?) [PROJECT].Droid, [PROJECT].UWP, [PROJECT].Wasm,
[PROJECT].iOS,
[PROJECT].macOS [PATH] \ [PROJECT].Shared\App.xaml.cs 116 Active
关于如何解决这个问题有什么想法吗?
将您的 Microsoft.Extensions.Logging.Console 和 Microsoft.Extensions.Logging.Filter nuget 包降级到版本 1.1.1
决定试用 Uno 平台,所以我按照此处的说明进行操作:https://platform.uno/docs/articles/get-started.html
在 VS2019 16.6.4 中使用 Cross-Platform App (Uno Platform) 模板设置新解决方案,然后更新所有 NuGet 包。
不更改一行代码,我无法构建解决方案(或只是 UWP 项目)。选择 UWP/x86 后,出现以下两个构建错误:
Error CS1929 'ILoggerFactory' does not contain a definition for 'AddConsole' and the best extension method overload 'ConsoleLoggerExtensions.AddConsole(ILoggingBuilder, Action)' requires a receiver of type 'ILoggingBuilder' [PROJECT].Droid, [PROJECT].UWP, [PROJECT].Wasm, [PROJECT].iOS, [PROJECT].macOS [PATH] \ [PROJECT].Shared\App.xaml.cs 116 Active
Error CS1061 'App' does not contain a definition for 'InitializeComponent' and no accessible extension method 'InitializeComponent' accepting a first argument of type 'App' could be found (are you missing a using directive or an assembly reference?) [PROJECT].Droid, [PROJECT].UWP, [PROJECT].Wasm, [PROJECT].iOS, [PROJECT].macOS [PATH] \ [PROJECT].Shared\App.xaml.cs 116 Active
关于如何解决这个问题有什么想法吗?
将您的 Microsoft.Extensions.Logging.Console 和 Microsoft.Extensions.Logging.Filter nuget 包降级到版本 1.1.1