You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: aspnetcore/blazor/call-javascript-from-dotnet.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -71,8 +71,8 @@ To use the <xref:Microsoft.JSInterop.IJSRuntime> abstraction, adopt any of the f
71
71
72
72
In the client-side sample app that accompanies this topic, two JavaScript functions are available to the app that interact with the DOM to receive user input and display a welcome message:
73
73
74
-
*`showPrompt`– Produces a prompt to accept user input (the user's name) and returns the name to the caller.
75
-
*`displayWelcome`– Assigns a welcome message from the caller to a DOM object with an `id` of `welcome`.
74
+
*`showPrompt`: Produces a prompt to accept user input (the user's name) and returns the name to the caller.
75
+
*`displayWelcome`: Assigns a welcome message from the caller to a DOM object with an `id` of `welcome`.
Copy file name to clipboardExpand all lines: aspnetcore/blazor/call-web-api.md
+7-7Lines changed: 7 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -57,9 +57,9 @@ The client's base address is set to the originating server's address. Inject an
57
57
58
58
In the following examples, a Todo web API processes create, read, update, and delete (CRUD) operations. The examples are based on a `TodoItem` class that stores the:
59
59
60
-
* ID (`Id`, `long`)– Unique ID of the item.
61
-
* Name (`Name`, `string`)– Name of the item.
62
-
* Status (`IsComplete`, `bool`)– Indication if the Todo item is finished.
60
+
* ID (`Id`, `long`): Unique ID of the item.
61
+
* Name (`Name`, `string`): Name of the item.
62
+
* Status (`IsComplete`, `bool`): Indication if the Todo item is finished.
63
63
64
64
```csharp
65
65
privateclassTodoItem
@@ -72,7 +72,7 @@ private class TodoItem
72
72
73
73
JSON helper methods send requests to a URI (a web API in the following examples) and process the response:
74
74
75
-
*<xref:System.Net.Http.Json.HttpClientJsonExtensions.GetFromJsonAsync%2A>– Sends an HTTP GET request and parses the JSON response body to create an object.
75
+
*<xref:System.Net.Http.Json.HttpClientJsonExtensions.GetFromJsonAsync%2A>: Sends an HTTP GET request and parses the JSON response body to create an object.
76
76
77
77
In the following code, the `todoItems` are displayed by the component. The `GetTodoItems` method is triggered when the component is finished rendering ([OnInitializedAsync](xref:blazor/lifecycle#component-initialization-methods)). See the sample app for a complete example.
78
78
@@ -88,7 +88,7 @@ JSON helper methods send requests to a URI (a web API in the following examples)
88
88
}
89
89
```
90
90
91
-
*<xref:System.Net.Http.Json.HttpClientJsonExtensions.PostAsJsonAsync%2A>– Sends an HTTP POST request, including JSON-encoded content, and parses the JSON response body to create an object.
91
+
*<xref:System.Net.Http.Json.HttpClientJsonExtensions.PostAsJsonAsync%2A>: Sends an HTTP POST request, including JSON-encoded content, and parses the JSON response body to create an object.
92
92
93
93
In the following code, `newItemName` is provided by a bound element of the component. The `AddItem` method is triggered by selecting a `<button>` element. See the sample app for a complete example.
94
94
@@ -116,7 +116,7 @@ JSON helper methods send requests to a URI (a web API in the following examples)
*<xref:System.Net.Http.Json.HttpClientJsonExtensions.PutAsJsonAsync%2A>– Sends an HTTP PUT request, including JSON-encoded content.
119
+
*<xref:System.Net.Http.Json.HttpClientJsonExtensions.PutAsJsonAsync%2A>: Sends an HTTP PUT request, including JSON-encoded content.
120
120
121
121
In the following code, `editItem` values for `Name` and `IsCompleted` are provided by bound elements of the component. The item's `Id` is set when the item is selected in another part of the UI and `EditItem` is called. The `SaveItem` method is triggered by selecting the Save `<button>` element. See the sample app for a complete example.
122
122
@@ -302,7 +302,7 @@ To allow other sites to make cross-origin resource sharing (CORS) requests to yo
302
302
303
303
## Additional resources
304
304
305
-
*<xref:security/blazor/webassembly/additional-scenarios>– Includes coverage on using <xref:System.Net.Http.HttpClient> to make secure web API requests.
305
+
*<xref:security/blazor/webassembly/additional-scenarios>: Includes coverage on using <xref:System.Net.Http.HttpClient> to make secure web API requests.
Copy file name to clipboardExpand all lines: aspnetcore/blazor/components.md
+3-3Lines changed: 3 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -70,8 +70,8 @@ Razor components in Blazor apps extensively use Razor syntax. If you aren't fami
70
70
71
71
When accessing the content on Razor syntax, pay special attention to the following sections:
72
72
73
-
*[Directives](xref:mvc/views/razor#directives)–`@`-prefixed reserved keywords that typically change the way component markup is parsed or function.
74
-
*[Directive attributes](xref:mvc/views/razor#directive-attributes)–`@`-prefixed reserved keywords that typically change the way component elements are parsed or function.
73
+
*[Directives](xref:mvc/views/razor#directives):`@`-prefixed reserved keywords that typically change the way component markup is parsed or function.
74
+
*[Directive attributes](xref:mvc/views/razor#directive-attributes):`@`-prefixed reserved keywords that typically change the way component elements are parsed or function.
75
75
76
76
## Static assets
77
77
@@ -975,7 +975,7 @@ However, inline SVG markup isn't supported in all scenarios. If you place an `<s
975
975
976
976
## Additional resources
977
977
978
-
*<xref:security/blazor/server/threat-mitigation>– Includes guidance on building Blazor Server apps that must contend with resource exhaustion.
978
+
*<xref:security/blazor/server/threat-mitigation>: Includes guidance on building Blazor Server apps that must contend with resource exhaustion.
Copy file name to clipboardExpand all lines: aspnetcore/blazor/dependency-injection.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -131,8 +131,8 @@ The DI system is based on the DI system in ASP.NET Core. For more information, s
131
131
132
132
After services are added to the service collection, inject the services into the components using the [\@inject](xref:mvc/views/razor#inject) Razor directive. [`@inject`](xref:mvc/views/razor#inject) has two parameters:
133
133
134
-
* Type– The type of the service to inject.
135
-
* Property– The name of the property receiving the injected app service. The property doesn't require manual creation. The compiler creates the property.
134
+
* Type: The type of the service to inject.
135
+
* Property: The name of the property receiving the injected app service. The property doesn't require manual creation. The compiler creates the property.
136
136
137
137
For more information, see <xref:mvc/views/dependency-injection>.
Copy file name to clipboardExpand all lines: aspnetcore/blazor/event-handling.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -84,7 +84,7 @@ Supported <xref:System.EventArgs> are shown in the following table.
84
84
For more information, see the following resources:
85
85
86
86
*[EventArgs classes in the ASP.NET Core reference source (dotnet/aspnetcore release/3.1 branch)](https://github.com/dotnet/aspnetcore/tree/release/3.1/src/Components/Web/src/Web).
87
-
*[MDN web docs: GlobalEventHandlers](https://developer.mozilla.org/docs/Web/API/GlobalEventHandlers)– Includes information on which HTML elements support each DOM event.
87
+
*[MDN web docs: GlobalEventHandlers](https://developer.mozilla.org/docs/Web/API/GlobalEventHandlers): Includes information on which HTML elements support each DOM event.
Copy file name to clipboardExpand all lines: aspnetcore/blazor/hosting-models.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -96,7 +96,7 @@ A Blazor app is composed of reusable elements of UI called *components*. A compo
96
96
* Turned into HTML text (during prerendering†).
97
97
* Used to efficiently update the markup during regular rendering.
98
98
99
-
†*Prerendering*– The requested Razor component is compiled on the server into static HTML and sent to the client, where it's rendered to the user. After the connection is made between the client and the server, the component's static prerendered elements are replaced with interactive elements. Prerendering makes the app feel more responsive to the user.
99
+
†*Prerendering*: The requested Razor component is compiled on the server into static HTML and sent to the client, where it's rendered to the user. After the connection is made between the client and the server, the component's static prerendered elements are replaced with interactive elements. Prerendering makes the app feel more responsive to the user.
Copy file name to clipboardExpand all lines: aspnetcore/blazor/integrate-components.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -17,10 +17,10 @@ Razor components can be integrated into Razor Pages and MVC apps. When the page
17
17
18
18
After [preparing the app](#prepare-the-app), use the guidance in the following sections depending on the app's requirements:
19
19
20
-
* Routable components– For components that are directly routable from user requests. Follow this guidance when visitors should be able to make an HTTP request in their browser for a component with an [`@page`](xref:mvc/views/razor#page) directive.
20
+
* Routable components: For components that are directly routable from user requests. Follow this guidance when visitors should be able to make an HTTP request in their browser for a component with an [`@page`](xref:mvc/views/razor#page) directive.
21
21
*[Use routable components in a Razor Pages app](#use-routable-components-in-a-razor-pages-app)
22
22
*[Use routable components in an MVC app](#use-routable-components-in-an-mvc-app)
23
-
*[Render components from a page or view](#render-components-from-a-page-or-view)– For components that aren't directly routable from user requests. Follow this guidance when the app embeds components into existing pages and views with the [Component Tag Helper](xref:mvc/views/tag-helpers/builtin-th/component-tag-helper).
23
+
*[Render components from a page or view](#render-components-from-a-page-or-view): For components that aren't directly routable from user requests. Follow this guidance when the app embeds components into existing pages and views with the [Component Tag Helper](xref:mvc/views/tag-helpers/builtin-th/component-tag-helper).
Copy file name to clipboardExpand all lines: aspnetcore/blazor/progressive-web-app.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -113,14 +113,14 @@ The built-in *service-worker.published.js* service worker resolves requests usin
113
113
114
114
The cache-first strategy is valuable because:
115
115
116
-
***It ensures reliability.**–Network access isn't a boolean state. A user isn't simply online or offline:
116
+
***It ensures reliability.** Network access isn't a boolean state. A user isn't simply online or offline:
117
117
118
118
* The user's device may assume it's online, but the network might be so slow as to be impractical to wait for.
119
119
* The network might return invalid results for certain URLs, such as when there's a captive WIFI portal that's currently blocking or redirecting certain requests.
120
120
121
121
This is why the browser's `navigator.onLine` API isn't reliable and shouldn't be depended upon.
122
122
123
-
***It ensures correctness.**–When building a cache of offline resources, the service worker uses content hashing to guarantee it has fetched a complete and self-consistent snapshot of resources at a single instant in time. This cache is then used as an atomic unit. There's no point asking the network for newer resources, since the only versions required are the ones already cached. Anything else risks inconsistency and incompatibility (for example, trying to use versions of .NET assemblies that weren't compiled together).
123
+
***It ensures correctness.** When building a cache of offline resources, the service worker uses content hashing to guarantee it has fetched a complete and self-consistent snapshot of resources at a single instant in time. This cache is then used as an atomic unit. There's no point asking the network for newer resources, since the only versions required are the ones already cached. Anything else risks inconsistency and incompatibility (for example, trying to use versions of .NET assemblies that weren't compiled together).
0 commit comments