C
C#17mo ago
Anton

❔ Is something like this possible with the default DI package?

So what I want to do is like this How scopes work normally: - global scope - scope 1 * scoped service A * scoped service B - scope 2 * scoped service A (different instance) * scoped service B (different instance) What I want is to be able to resolve scoped services of the parent from a subscope, but create new services for some types in subscopes (are there even subscopes?) - global scope - scope 1 * service A - scope 1.1 * service A resolved to the one of the parent * service B - scope 1.2 * different instance of service B I've seen a lib allow this, but it's for Unity. They did it through custom scope classes. Autofac might allow this too? I'm not sure.
2 Replies
Anton
Anton17mo ago
what the heck are these lists bruh to be clear, I want A to always resolve at the parent scope level
Accord
Accord17mo ago
Looks like nothing has happened here. I will mark this as stale and this post will be archived until there is new activity.