-
Notifications
You must be signed in to change notification settings - Fork 264
Closed
Description
Link to specs:
Original issue description
Project files in .NET Core 3.0 will be able to use FrameworkReferences to declare a dependency on optional shared frameworks such as ASP.NET or WPF/WinForms. Currently, a FrameworkReference is expressed like this in a project file:
<ItemGroup>
<FrameworkReference Include="Microsoft.DesktopUI"/>
</ItemGroup>If a project references a NuGet package or another project that depends on an optional shared framework, then that shared framework dependency should flow from the referenced package or project to the app. This means that FrameworkReferences need to be represented in some way in a NuGet package. We have discussed using the existing frameworkAssembly element for this.
The behavior needed in NuGet would be:
- During the Pack operation, translate the project's
FrameworkReferenceitems into the format that they are expressed in the .nuspec (probablyframeworkAssembly) - During restore, write FrameworkReference dependencies from referenced packages to the assets file. If
frameworkAssemblyis used to express these dependencies, then this may happen with little or no code changes - During restore, write
FrameworkReferenceinformation from referenced projects to the assets file. This enables framework references to flow across (possibly transitive) project references