Skip to content

Commit 0f08105

Browse files
Copilotjaviercn
andcommitted
Add StyleBundleName generator to MVC and Razor Pages templates to fix space handling
Co-authored-by: javiercn <[email protected]>
1 parent ed6df20 commit 0f08105

File tree

4 files changed

+28
-2
lines changed

4 files changed

+28
-2
lines changed

src/ProjectTemplates/Web.ProjectTemplates/content/RazorPagesWeb-CSharp/.template.config/template.json

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -321,6 +321,19 @@
321321
},
322322
"replaces": "44300"
323323
},
324+
"StyleBundleName":{
325+
"type": "generated",
326+
"generator": "regex",
327+
"replaces": "StyleBundleName",
328+
"parameters": {
329+
"source": "name",
330+
"steps": [
331+
{
332+
"regex": " ",
333+
"replacement": "_"
334+
}]
335+
}
336+
},
324337
"OrganizationalAuth": {
325338
"type": "computed",
326339
"value": "(auth == \"SingleOrg\" || auth == \"MultiOrg\")"

src/ProjectTemplates/Web.ProjectTemplates/content/RazorPagesWeb-CSharp/Pages/Shared/_Layout.cshtml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<script type="importmap"></script>
88
<link rel="stylesheet" href="~/lib/bootstrap/dist/css/bootstrap.min.css" />
99
<link rel="stylesheet" href="~/css/site.css" asp-append-version="true" />
10-
<link rel="stylesheet" href="~/Company.WebApplication1.styles.css" asp-append-version="true" />
10+
<link rel="stylesheet" href="~/StyleBundleName.styles.css" asp-append-version="true" />
1111
</head>
1212
<body>
1313
<header>

src/ProjectTemplates/Web.ProjectTemplates/content/StarterWeb-CSharp/.template.config/template.json

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -311,6 +311,19 @@
311311
},
312312
"replaces": "44300"
313313
},
314+
"StyleBundleName":{
315+
"type": "generated",
316+
"generator": "regex",
317+
"replaces": "StyleBundleName",
318+
"parameters": {
319+
"source": "name",
320+
"steps": [
321+
{
322+
"regex": " ",
323+
"replacement": "_"
324+
}]
325+
}
326+
},
314327
"OrganizationalAuth": {
315328
"type": "computed",
316329
"value": "(auth == \"SingleOrg\" || auth == \"MultiOrg\")"

src/ProjectTemplates/Web.ProjectTemplates/content/StarterWeb-CSharp/Views/Shared/_Layout.cshtml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<script type="importmap"></script>
88
<link rel="stylesheet" href="~/lib/bootstrap/dist/css/bootstrap.min.css" />
99
<link rel="stylesheet" href="~/css/site.css" asp-append-version="true" />
10-
<link rel="stylesheet" href="~/Company.WebApplication1.styles.css" asp-append-version="true" />
10+
<link rel="stylesheet" href="~/StyleBundleName.styles.css" asp-append-version="true" />
1111
</head>
1212
<body>
1313
<header>

0 commit comments

Comments
 (0)