Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions aspnetcore/blazor/components/integration.md
Original file line number Diff line number Diff line change
Expand Up @@ -179,6 +179,12 @@ To support routable Razor components in Razor Pages apps:

> [!NOTE]
> The preceding example assumes that the <xref:Microsoft.AspNetCore.Components.Web.HeadOutlet> component and Blazor script (`_framework/blazor.server.js`) are rendered by the app's layout. For more information, see the [Configuration](#configuration) section.
>
> In .NET 10 or later, the Blazor script is included by the framework if the project contains at least one Razor component file (`.razor`). If your app requires the Blazor script but doesn't contain at least one component, add the following MSBuild property to the app's project file to force unconditional script inclusion:
>
> ```xml
> <RequiresAspNetWebAssets>true</RequiresAspNetWebAssets>
> ```

<xref:Microsoft.AspNetCore.Mvc.Rendering.RenderMode> configures whether the `App` component:

Expand Down Expand Up @@ -260,6 +266,12 @@ To support routable Razor components in MVC apps:

> [!NOTE]
> The preceding example assumes that the <xref:Microsoft.AspNetCore.Components.Web.HeadOutlet> component and Blazor script (`_framework/blazor.server.js`) are rendered by the app's layout. For more information, see the [Configuration](#configuration) section.
>
> In .NET 10 or later, the Blazor script is included by the framework if the project contains at least one Razor component file (`.razor`). If your app requires the Blazor script but doesn't contain at least one component, add the following MSBuild property to the app's project file to force unconditional script inclusion:
>
> ```xml
> <RequiresAspNetWebAssets>true</RequiresAspNetWebAssets>
> ```

<xref:Microsoft.AspNetCore.Mvc.Rendering.RenderMode> configures whether the `App` component:

Expand Down
16 changes: 8 additions & 8 deletions aspnetcore/blazor/project-structure.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,11 +70,11 @@ The `Components/Pages` folder of the server project contains the app's routable
Add the angle brackets around the cross-link when
activating.

:::moniker range=">= aspnetcore-10.0"
moniker range=">= aspnetcore-10.0"

The `NotFound` component (`NotFound.razor`) implements a Not Found page to display when content isn't found for a request path. For more information, see xref:blazor/fundamentals/navigation#not-found-responses.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This text is not showing as intended when the version selector is set to .NET 10.0

Copy link
Collaborator Author

@guardrex guardrex Dec 1, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(ugh, I accidently deleted this thinking I had clicked to reply on your quote, sorry).

Original comment ...

It's commented out on purpose. It shouldn't show up in the review article (or the live article for that matter) at this time.

I think the problem is that with the triple-colon syntax inside HTML comments, the build system is flaking out and breaking the article for some versions. I think that this is the same problem that you noted when working on the not-current-release INCLUDES file. See the live 7.0 article at ...

https://learn.microsoft.com/en-us/aspnet/core/blazor/project-structure?view=aspnetcore-7.0

AFAIK, that should be rendering correctly with the versioning tags in place in the article. I think it's the commented-out triple-colon lines that are causing the problem with that broken 7.0 (and earlier) rendering.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

... and btw just as a side-note ...

Looks like the version is wrong here ...

image

Copy link
Contributor

@wadepickett wadepickett Dec 1, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"It's commented out on purpose."

@guardrex, maybe we are we talking about the same text? It is the following text I am referring to below. It looks like it was intended to show in 10 but does not show in 10:

"The NotFound component (NotFound.razor) implements a Not Found page to display when content isn't found for a request path. For more information, see xref:blazor/fundamentals/navigation#not-found-responses."

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, per Line 66 ... this bit (Line 75 inclusive) shouldn't appear at this time.

Copy link
Collaborator Author

@guardrex guardrex Dec 1, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The commented-out text runs from Line 66 to Line 79.

I'm just seeking to remove the triple-colons from this HTML comment block to try and resurface the MIA parts of the article 🤞🍀 ... if the server gods will bless the attempt 🙏😄.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If the 7.0 version of the article, which is currently ...

https://learn.microsoft.com/en-us/aspnet/core/blazor/project-structure?view=aspnetcore-7.0

... gets its content back in the review 7.0 article (which I can't see), then these changes work ... it is the triple-colon syntax in HTML comments that breaks article rendering, which I think is what you saw on that not-latest-version INCLUDES file PR from a week or two ago.


:::moniker-end
moniker-end

-->

Expand Down Expand Up @@ -332,19 +332,19 @@ Project structure:
Add the angle brackets around the cross-link when
activating.

:::moniker-end
moniker-end

:::moniker range=">= aspnetcore-10.0"
moniker range=">= aspnetcore-10.0"

* `Pages` folder: Contains the Blazor app's routable Razor components (`.razor`). The route for each page is specified using the [`@page`](xref:mvc/views/razor#page) directive. The template includes the following components:
* `Counter` component (`Counter.razor`): Implements the Counter page.
* `Index` component (`Index.razor`): Implements the Home page.
* `Weather` component (`Weather.razor`): Implements the Weather page.
* `NotFound` component (`NotFound.razor`) Implements a Not Found page to display when content isn't found for a request path. For more information, see xref:blazor/fundamentals/navigation#not-found-responses.

:::moniker-end
moniker-end

:::moniker range=">= aspnetcore-8.0 < aspnetcore-10.0"
moniker range=">= aspnetcore-8.0 < aspnetcore-10.0"

-->

Expand All @@ -357,9 +357,9 @@ Project structure:
https://github.com/dotnet/AspNetCore.Docs/pull/36145
is merged.

:::moniker-end
moniker-end

:::moniker range=">= aspnetcore-8.0"
moniker range=">= aspnetcore-8.0"

-->

Expand Down
6 changes: 6 additions & 0 deletions aspnetcore/release-notes/aspnetcore-10/includes/blazor.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,12 @@ For more information, see <xref:blazor/components/quickgrid?view=aspnetcore-10.0

In prior releases of .NET, the Blazor script is served from an embedded resource in the ASP.NET Core shared framework. In .NET 10 or later, the Blazor script is served as a static web asset with automatic compression and fingerprinting.

The Blazor script (`blazor.web.js` or `blazor.server.js`) is included by the framework if the project contains at least one Razor component file (`.razor`). If your app requires the Blazor script but doesn't contain at least one component, add the following MSBuild property to the app's project file to force unconditional script inclusion:

```xml
<RequiresAspNetWebAssets>true</RequiresAspNetWebAssets>
```

For more information, see the following resources:

* <xref:blazor/project-structure?view=aspnetcore-10.0#location-of-the-blazor-script>
Expand Down