Skip to content

Commit f1ed2df

Browse files
authored
Include .Views.dll from single file in .NET Core 3.1 apps (#27897)
For 5.0, we made a change to exclude .Views.dll from the single file bundle as a reaction to changes in bundling. However the SDK change also applied to .NET 3.1 apps. This change limits the exclusion to 5.0 and newer apps. Fixes #27831
1 parent de177e3 commit f1ed2df

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/Razor/Microsoft.NET.Sdk.Razor/src/build/netstandard2.0/Sdk.Razor.CurrentVersion.targets

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -724,12 +724,13 @@ Copyright (c) .NET Foundation. All rights reserved.
724724
<AllPublishItemsFullPathWithTargetPath Include="@(RazorIntermediateAssembly->'%(FullPath)')">
725725
<TargetPath>%(Filename)%(Extension)</TargetPath>
726726
<CopyToPublishDirectory>PreserveNewest</CopyToPublishDirectory>
727-
<ExcludeFromSingleFile>true</ExcludeFromSingleFile>
727+
<!-- .Views.dll and .Views.pdb were part of the single file bundle in 3.1 apps. Lets keep this unchanged. -->
728+
<ExcludeFromSingleFile Condition="'$(_TargetingNET50OrLater)' == 'true'">true</ExcludeFromSingleFile>
728729
</AllPublishItemsFullPathWithTargetPath>
729730
<AllPublishItemsFullPathWithTargetPath Include="@(_RazorDebugSymbolsIntermediatePath->'%(FullPath)')">
730731
<TargetPath>%(Filename)%(Extension)</TargetPath>
731732
<CopyToPublishDirectory>PreserveNewest</CopyToPublishDirectory>
732-
<ExcludeFromSingleFile>true</ExcludeFromSingleFile>
733+
<ExcludeFromSingleFile Condition="'$(_TargetingNET50OrLater)' == 'true'">true</ExcludeFromSingleFile>
733734
</AllPublishItemsFullPathWithTargetPath>
734735
</ItemGroup>
735736

0 commit comments

Comments
 (0)