Injecting a property into a singleton service in Prism (Unity, MVVM)
问题 For reference, I have a service that I want to register as a singleton in the unity container. I want this service to have the IEventAggerator injected into the service somehow, either by property or constructor injection. public class BeckhoffService: IProgrammableLogicController { ...} and I'll either want this: [Dependency] public IEventAggregator eventAggregator{get;set;} or in the constructor: BeckhoffService(IEventAggregator eventAggregator) My issue comes when I register this service