c# - DryIoc The type 'Rules' exists in both 'DryIoc.Shared and DryIoc - Stack Overflow

admin2025-04-25  2

We are getting the following compiler error when trying to create a container extension with DryIoc container

DryIoc The type Rules exists in both DryIoc.Shared and DryIoc

using Prism.Ioc;
using Prism.Container.DryIoc;
using Prism.Events;
using DryIoc;
 
  var containerRegistry = new 
     DryIocContainerExtension(Rules.MicrosoftDependencyInjectionRules);

The following packages are in the cproj file

       <PackageReference Include="Prism.Avalonia" Version="9.0.401.11110-pre" />
        <PackageReference Include="Prism.DryIoc.Avalonia" Version="9.0.401.11110-pre" />

How to get this code to compile?

转载请注明原文地址:http://anycun.com/QandA/1745530037a90822.html