Skip to content

Commit 30cca49

Browse files
committed
Use exact runtime for non-servicing builds of Blazor DevServer
1 parent a69aabf commit 30cca49

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

src/Components/WebAssembly/DevServer/src/Microsoft.AspNetCore.Components.WebAssembly.DevServer.csproj

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,11 @@
3636

3737
<Target Name="_CreateRuntimeConfig" BeforeTargets="CoreBuild">
3838
<PropertyGroup>
39-
<_RuntimeConfigProperties>
40-
AspNetCoreMajorMinorVersion=$(AspNetCoreMajorMinorVersion);
39+
<_RuntimeConfigProperties Condition="'$(IsServicingBuild)' == 'true'">
40+
FrameworkVersion=$(AspNetCoreMajorMinorVersion).0;
41+
</_RuntimeConfigProperties>
42+
<_RuntimeConfigProperties Condition="'$(IsServicingBuild)' != 'true'">
43+
FrameworkVersion=$(SharedFxVersion);
4144
</_RuntimeConfigProperties>
4245

4346
<_RuntimeConfigPath>$(OutputPath)blazor-devserver.runtimeconfig.json</_RuntimeConfigPath>

src/Components/WebAssembly/DevServer/src/blazor-devserver.runtimeconfig.json.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"tfm": "net8.0",
44
"framework": {
55
"name": "Microsoft.AspNetCore.App",
6-
"version": "${AspNetCoreMajorMinorVersion}.0"
6+
"version": "${FrameworkVersion}"
77
},
88
"rollForwardOnNoCandidateFx": 2
99
}

0 commit comments

Comments
 (0)