cloudscribe/cloudscribe.Web.Navigation

Warning of conflict views

Closed this issue · 4 comments

Hi, I upgraded from 2.0.x to 2.1.x and now I get a warning that there are conflicts between the views in my project and the embedded versions.
How can I fix that? Can't find any release note about it. I have my views in \Views\Shared\Components\Navigation.

Also, where can I find the latest version of the embedded views? In that way, I can use those as starting point.

Thanks

The latest views can be found here:
https://github.com/cloudscribe/cloudscribe.Web.Navigation/tree/master/src/cloudscribe.Web.Navigation/Views/Shared

In my projects I suppress the warnings about views because they are only warnings and the local views win the conflict by default which is the desired behavior.

<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
    <NoWarn>1701;1702;0436</NoWarn>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
    <NoWarn>1701;1702;0436</NoWarn>
</PropertyGroup>

forgot to mention those warning suppressions go in the .csproj file

Suppressing is fine. I thought maybe there is some setting.

One additional question. What if you override a few views? Will the embedded views be used for the others? I presume it will...

yes, that is correct, best to only override the views you want to change and let the rest be used directly from the nuget.

Note that early versions were embedded resources and compiled at runtime but after aspnetcore 2 was released with support for Razor class libraries, now the views in the nuget are pre-compiled rather than embedded.