Main Goal: I want to create a library with fewer dependencies as possible.
The Problem:
I have a .Net Standard
library (a.dll
) that references a NuGet package (package
) for internal usages.I tried to achieve the following behavior when a user referencing a.dll
:
- The user will not have any access to the
package
classes and methods. - The user will be able to reference a different version of the
package
and both versions will be loaded to the process.
How can I achieve this behavior?
Possible Solution: Copy the package code and change the assembly name and all the modifier access to internal. Big disadvantage: very difficult to maintain.