{"id":308943,"date":"2020-08-24T21:00:27","date_gmt":"2020-08-24T21:00:27","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=308943"},"modified":"-0001-11-30T00:00:00","modified_gmt":"2020-08-24T21:00:27","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=308943","title":{"rendered":"\u041e\u0431\u044a\u0435\u0434\u0438\u043d\u044f\u0435\u043c Blazor \u0438 Razor Pages \u0432 \u043e\u0434\u043d\u043e\u043c ASP.NET Core 3 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0438"},"content":{"rendered":"\n<div class=\"post__text post__text-html post__text_v1\" id=\"post-content-body\" data-io-article-url=\"https:\/\/habr.com\/ru\/company\/otus\/blog\/516434\/\"><b><i>\u041f\u0435\u0440\u0435\u0432\u043e\u0434 \u0441\u0442\u0430\u0442\u044c\u0438 \u043f\u043e\u0434\u0433\u043e\u0442\u043e\u0432\u043b\u0435\u043d \u0432 \u043f\u0440\u0435\u0434\u0434\u0432\u0435\u0440\u0438\u0438 \u0441\u0442\u0430\u0440\u0442\u0430 \u043a\u0443\u0440\u0441\u0430 <a href=\"https:\/\/otus.pw\/IFnr\/\">\u00abC# ASP.NET Core \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u00bb<\/a>.<\/i><\/b><\/p>\n<hr>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/4l\/5e\/am\/4l5eamg4cnptjngsacl7b_jlgze.png\"><\/p>\n<p>  \u0412 \u044d\u0442\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u044f \u0440\u0430\u0441\u0441\u043a\u0430\u0436\u0443, \u043a\u0430\u043a \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u043d\u0430 \u043e\u0441\u043d\u043e\u0432\u0435 Blazor \u0432 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0435\u0435 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 Razor Pages. <\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/vu\/jb\/cn\/vujbcnfwes3zpa1propbz5s4bfa.gif\"><\/p>\n<h3>\u041f\u0440\u0435\u0434\u0438\u0441\u043b\u043e\u0432\u0438\u0435<\/h3>\n<p>  \u0412\u044b\u0445\u043e\u0434 Blazor \u043d\u0430 \u0437\u043e\u043b\u043e\u0442\u043e <a href=\"https:\/\/www.dotnetconf.net\/\">\u0434\u043e\u043b\u0436\u0435\u043d \u043f\u0440\u043e\u0438\u0437\u043e\u0439\u0442\u0438 \u0447\u0435\u0440\u0435\u0437 \u0434\u0432\u0435 \u043d\u0435\u0434\u0435\u043b\u0438<\/a>. \u041c\u043d\u043e\u0433\u0438\u0435 \u0432\u0435\u0449\u0438 \u0432 \u043f\u0440\u043e\u0435\u043a\u0442\u0435 \u0435\u0449\u0435 \u043f\u043e\u0434\u0432\u0435\u0440\u0436\u0435\u043d\u044b \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0440\u0435\u0437\u043a\u0438\u043c \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u044f\u043c, \u0438 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u044f\u044f \u043f\u0440\u0435\u0434\u0432\u0430\u0440\u0438\u0442\u0435\u043b\u044c\u043d\u0430\u044f 9-\u044f \u0432\u0435\u0440\u0441\u0438\u044f \u0437\u043d\u0430\u0447\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0443\u0441\u043b\u043e\u0436\u043d\u0438\u043b\u0430 \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435 \u043c\u0435\u0436\u0434\u0443 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u0430\u043c\u0438 Razor Pages \u0438 Blazor: <a href=\"https:\/\/github.com\/aspnet\/AspNetCore\/issues\/13721\">\u0442\u0435\u043f\u0435\u0440\u044c \u043d\u0435\u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e \u043f\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u0442\u044c \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b<\/a> \u0438\u0437 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b Razor \u0432 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442 Blazor \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e<code> Html.RenderComponentAsync<\/code>. \u042d\u0442\u043e \u043c\u043e\u0436\u0435\u0442 \u0438\u0437\u043c\u0435\u043d\u0438\u0442\u044c\u0441\u044f \u0432 \u0431\u0443\u0434\u0443\u0449\u0435\u043c, \u043d\u043e \u0432\u043f\u043e\u043b\u043d\u0435 \u0432\u0435\u0440\u043e\u044f\u0442\u043d\u043e, \u0447\u0442\u043e \u0432 .NET Core 3.0 \u043e\u043d \u043f\u043e\u044f\u0432\u0438\u0442\u0441\u044f \u0441 \u044d\u0442\u0438\u043c \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u0438\u0435\u043c.<\/p>\n<p>  \u0415\u0441\u043b\u0438 \u0432\u044b \u0432\u0441\u0435 \u0436\u0435 \u0445\u043e\u0442\u0438\u0442\u0435 \u0443\u043b\u0443\u0447\u0448\u0438\u0442\u044c \u0441\u0432\u043e\u0435 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0435\u0435 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u043d\u0430 \u043e\u0441\u043d\u043e\u0432\u0435 Razor Pages \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e Blazor-\u043c\u0430\u0433\u0438\u0438, \u043e\u0434\u043d\u043e \u0438\u0437 \u0440\u0435\u0448\u0435\u043d\u0438\u0439 \u2014 \u043f\u043e\u043b\u043d\u043e\u0441\u0442\u044c\u044e \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u0442\u044c \u0441\u0432\u043e\u0438 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u0432 Blazor. \u0412 \u044d\u0442\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u044f \u043f\u043e\u043a\u0430\u0436\u0443, \u043a\u0430\u043a \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0442\u044c Blazor-\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u0432 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0435\u0435 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u043d\u0430 \u043e\u0441\u043d\u043e\u0432\u0435 Razor Pages, \u0433\u0434\u0435 \u043e\u0434\u043d\u0438 \u0447\u0430\u0441\u0442\u0438 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u0441\u043e\u0437\u0434\u0430\u044e\u0442\u0441\u044f \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e Razor Pages, \u0430 \u0434\u0440\u0443\u0433\u0438\u0435 \u2014 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e Blazor Pages. \u0414\u043b\u044f \u043e\u0431\u043e\u0438\u0445 \u0442\u0438\u043f\u043e\u0432 \u0441\u0442\u0440\u0430\u043d\u0438\u0446 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f <b>\u043e\u0434\u0438\u043d\u0430\u043a\u043e\u0432\u044b\u0439 \u043c\u0430\u043a\u0435\u0442.<\/b><a name=\"habracut\"><\/a><\/p>\n<h3>\u0428\u0430\u0433 \u043f\u0435\u0440\u0432\u044b\u0439: \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0430 Blazor<\/h3>\n<p>  \u0418\u0442\u0430\u043a, \u0443 \u043d\u0430\u0441 \u0435\u0441\u0442\u044c \u0443\u0436\u0435 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0435\u0435 Razor Pages \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u0431\u044b\u043b\u043e \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u043d\u043e \u0432 .NET Core 3.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/sc\/__\/0m\/sc__0mddnekkcqpome6naz8lmuk.png\"><\/p>\n<p>  \u0414\u043b\u044f \u043d\u0430\u0447\u0430\u043b\u0430, \u0432\u0430\u043c \u043d\u0443\u0436\u043d\u043e \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u0432 \u0441\u0432\u043e\u0435 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0443 Blazor. \u042d\u0442\u0430 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0430 \u043f\u043e\u0437\u0432\u043e\u043b\u0438\u0442 \u0432\u0430\u043c \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0442\u044c Blazor-\u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u044b \u0441 Razor-\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b. <a href=\"https:\/\/docs.microsoft.com\/en-us\/aspnet\/core\/blazor\/hosting-models?view=aspnetcore-3.0\">\u041e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u0430\u044f \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u044f<\/a> \u043f\u043e\u043b\u043d\u043e\u0441\u0442\u044c\u044e \u043f\u0440\u043e\u0432\u043e\u0434\u0438\u0442 \u0432\u0430\u0441 \u043f\u043e \u044d\u0442\u043e\u043c\u0443 \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0443, \u043d\u043e \u0432\u043e\u0442 \u0435\u0433\u043e \u043a\u0440\u0430\u0442\u043a\u043e\u0435 \u0438\u0437\u043b\u043e\u0436\u0435\u043d\u0438\u0435.<\/p>\n<p>  <b>Startup.cs:<\/b><\/p>\n<p>  \u041d\u0430\u043c \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c <code>Services.AddServerSideBlazor<\/code> \u0432 <code>ConfigureServices<\/code> \u0438 <code>endpoints.MapBlazorHub<\/code> \u0432 <code>Configure<\/code>:<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/in\/m7\/qg\/inm7qgbdkextemp3vmkc1d6pnc8.png\"><\/p>\n<p>  <b>_Layout.cshtml:<\/b><\/p>\n<p>  JS-\u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430 Blazor \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u0430 \u0434\u043b\u044f \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f Blazor \u043d\u0430 \u0441\u0442\u043e\u0440\u043e\u043d\u0435 \u0441\u0435\u0440\u0432\u0435\u0440\u0430. \u041e\u043d\u0430 \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u0434\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u0430 \u0432 <code>_Layout.cshtml<\/code>:<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/3k\/7t\/jn\/3k7tjnvav4vr76gz_idesqxnq2g.png\"><\/p>\n<p>  <a href=\"https:\/\/mikaelkoskinen.net\/post\/combining-razor-blazor-pages-single-asp-net-core-3-application#\">?<\/a>  <\/p>\n<pre><code class=\"javascript\">&lt;script src=&quot;_framework\/blazor.server.js&quot;&gt;&lt;\/script&gt;<\/code><\/pre>\n<p>  <b>_Imports.razor:<\/b><\/p>\n<p>  \u041d\u0430\u043c \u0442\u0430\u043a\u0436\u0435 \u043f\u043e\u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f \u043d\u043e\u0432\u044b\u0439 \u0444\u0430\u0439\u043b \u0441 \u0438\u043c\u0435\u043d\u0435\u043c <code>_Imports.razor<\/code>. \u041e\u043d \u0434\u043e\u043b\u0436\u0435\u043d \u0431\u044b\u0442\u044c \u0434\u043e\u0431\u0430\u0432\u043b\u0435\u043d \u0432 \u043f\u0430\u043f\u043a\u0443 Pages:<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/sk\/bw\/uc\/skbwucmsipepfm1si23rv-ginnk.png\"><\/p>\n<p>  <code>_Imports.razor<\/code> \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f \u0434\u043b\u044f \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 using-\u0432\u044b\u0440\u0430\u0436\u0435\u043d\u0438\u0439 \u0434\u043b\u044f \u0432\u0430\u0448\u0438\u0445 Blazor-\u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u043e\u0432. \u041d\u0430\u0447\u0430\u0442\u044c \u043c\u043e\u0436\u043d\u043e \u0441\u043e \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0433\u043e:<\/p>\n<p>  <a href=\"https:\/\/mikaelkoskinen.net\/post\/combining-razor-blazor-pages-single-asp-net-core-3-application#\">?<\/a>  <\/p>\n<pre><code class=\"cs\">@using System.Net.Http @using Microsoft.AspNetCore.Components.Forms @using Microsoft.AspNetCore.Components.Routing @using Microsoft.JSInterop @using Microsoft.AspNetCore.Components.Web<\/code><\/pre>\n<p>  <b>\u0418 \u043d\u0430 \u044d\u0442\u043e\u043c \u0432\u0441\u0435<\/b>. \u0422\u0435\u043f\u0435\u0440\u044c \u043d\u0430\u0448\u0435 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0435\u0442 Blazor. \u041c\u044b \u043c\u043e\u0436\u0435\u043c \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c \u044d\u0442\u043e, \u0441\u043a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u0432 \u043a\u043b\u0430\u0441\u0441\u0438\u0447\u0435\u0441\u043a\u0438\u0439 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442 Counter (\u0441\u0447\u0435\u0442\u0447\u0438\u043a) \u0432 \u043d\u0430\u0448\u0435 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/w5\/ss\/j4\/w5ssj41icksxtsc5-h757n2t38g.png\"><\/p>\n<p>  <a href=\"https:\/\/mikaelkoskinen.net\/post\/combining-razor-blazor-pages-single-asp-net-core-3-application#\">?<\/a>  <\/p>\n<pre><code class=\"cs\">@page &quot;\/counter&quot;   &lt;h1&gt;Counter&lt;\/h1&gt;  &lt;p&gt;Current count: @currentCount&lt;\/p&gt;   &lt;button class=&quot;btn btn-primary&quot; @onclick=&quot;IncrementCount&quot;&gt;Click me&lt;\/button&gt;   @code {     int currentCount = 0;       void IncrementCount()     {         currentCount++;     } }<\/code><\/pre>\n<p>  \u0418 \u043e\u0442\u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u0443\u0435\u043c <code>Privacy.cshtml<\/code>, \u0447\u0442\u043e\u0431\u044b \u0432\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442 Counter:<\/p>\n<pre><code class=\"cs\">&lt;a href=&quot;https:\/\/mikaelkoskinen.net\/post\/combining-razor-blazor-pages-single-asp-net-core-3-application#&quot;&gt;?&lt;\/a&gt; @page @model PrivacyModel @{     ViewData[&quot;Title&quot;] = &quot;Privacy Policy&quot;; } &lt;h1&gt;@ViewData[&quot;Title&quot;]&lt;\/h1&gt;   &lt;p&gt;Use this page to detail your site's privacy policy.&lt;\/p&gt;   &lt;component&gt;@(await Html.RenderComponentAsync&lt;Counter&gt;(RenderMode.Server))&lt;\/component&gt;<\/code><\/pre>\n<p>  \u0422\u0435\u043f\u0435\u0440\u044c, \u043a\u043e\u0433\u0434\u0430 \u043c\u044b \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u043c \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435, \u043d\u0430 \u043d\u0430\u0448\u0435\u0439 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0435 \u0434\u043e\u043b\u0436\u0435\u043d \u043f\u043e\u044f\u0432\u0438\u0442\u0441\u044f \u0440\u0430\u0431\u043e\u0447\u0438\u0439 Counter:<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/2v\/v2\/wz\/2vv2wzzmikduju2ysnepbfpm2i4.gif\"><\/p>\n<p>  \u0412 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0439 \u0447\u0430\u0441\u0442\u0438 \u044d\u0442\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0438 \u044f \u043f\u043e\u043a\u0430\u0436\u0443, \u043a\u0430\u043a \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0438\u0437\u043c\u0435\u043d\u0438\u0442\u044c \u0441\u0432\u043e\u0435 Razor Pages \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435, \u0447\u0442\u043e\u0431\u044b \u0432\u043c\u0435\u0441\u0442\u043e \u043f\u0440\u043e\u0441\u0442\u043e\u0433\u043e \u0434\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u043e\u0432 \u043d\u0430 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0435 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u0432\u044b \u043c\u043e\u0433\u043b\u0438 \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u0442\u044c \u043f\u043e\u043b\u043d\u043e\u0446\u0435\u043d\u043d\u044b\u0435 Blazor-\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b.<\/p>\n<h3>\u0428\u0430\u0433 \u0432\u0442\u043e\u0440\u043e\u0439: \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0430 Blazor Pages<\/h3>\n<p>  \u041d\u0430\u0448 Blazor-\u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0435\u0442 \u043c\u0430\u0440\u0448\u0440\u0443\u0442 <code>\u201c\/counter\u201d<\/code>:<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/m8\/kr\/zx\/m8krzxvq1om7g4v2kmnymsobwhy.png\"><\/p>\n<p>  \u041d\u043e \u043f\u0435\u0440\u0435\u0445\u043e\u0434 \u043f\u043e \u043d\u0435\u043c\u0443 \u043d\u0435 \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442:<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/uj\/dt\/91\/ujdt91chjusssazfduf00hzvej0.png\"><\/p>\n<p>  \u041d\u0430\u0448\u0430 \u0446\u0435\u043b\u044c \u2014 \u0437\u0430\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u043c\u0430\u0440\u0448\u0440\u0443\u0442\u0438\u0437\u0430\u0446\u0438\u044e \u043d\u0430 Blazor-\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b. \u0418 \u043c\u044b \u0445\u043e\u0442\u0438\u043c, \u0447\u0442\u043e\u0431\u044b Blazor-\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043b\u0438 \u0442\u043e\u0442 \u0436\u0435 \u043c\u0430\u043a\u0435\u0442, \u0447\u0442\u043e \u0438 Razor-\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b. \u0414\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043d\u0430\u043c \u043f\u043e\u043d\u0430\u0434\u043e\u0431\u0438\u0442\u0441\u044f \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0432\u0435\u0449\u0435\u0439, \u043d\u0430\u0447\u0438\u043d\u0430\u044f \u0441 <a href=\"https:\/\/docs.microsoft.com\/en-us\/aspnet\/core\/blazor\/routing?view=aspnetcore-3.0\">\u043c\u0430\u0440\u0448\u0440\u0443\u0442\u0438\u0437\u0430\u0442\u043e\u0440\u0430 (Router)<\/a>.<\/p>\n<p>  <b>App.razor:<\/b><\/p>\n<p>  \u0421\u043e\u0437\u0434\u0430\u0439\u0442\u0435 \u043d\u043e\u0432\u044b\u0439 \u0444\u0430\u0439\u043b <code>App.razor<\/code> \u0432 \u043f\u0430\u043f\u043a\u0435 <\/p>\n<pre><code class=\"1c\">Pages<\/code><\/pre>\n<p>:<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/-1\/ti\/is\/-1tiisxittmjunowyojforonew8.png\"><\/p>\n<p>  \u041a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442 Router \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d \u0432 <code>App.razor<\/code>:<\/p>\n<p>  <a href=\"https:\/\/mikaelkoskinen.net\/post\/combining-razor-blazor-pages-single-asp-net-core-3-application#\">?<\/a><\/p>\n<pre><code class=\"cs\">@using Microsoft.AspNetCore.Components.Routing   &lt;Router AppAssembly=&quot;typeof(Program).Assembly&quot;&gt;     &lt;Found Context=&quot;routeData&quot;&gt;         &lt;RouteView RouteData=&quot;routeData&quot;\/&gt;     &lt;\/Found&gt;     &lt;NotFound&gt;         &lt;h1&gt;Page not found&lt;\/h1&gt;         &lt;p&gt;Sorry, but there's nothing here!&lt;\/p&gt;     &lt;\/NotFound&gt; &lt;\/Router&gt;<\/code><\/pre>\n<p>  Router \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u043f\u0440\u043e\u0441\u043c\u0430\u0442\u0440\u0438\u0432\u0430\u0435\u0442 \u0432\u0441\u0435 Blazor-\u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u044b \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e page-\u0434\u0438\u0440\u0435\u043a\u0442\u0438\u0432\u044b \u0438 \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u0442 \u043a \u043d\u0438\u043c \u043c\u0430\u0440\u0448\u0440\u0443\u0442\u044b.<\/p>\n<p>  <b>_Host.cshtml:<\/b><\/p>\n<p>  \u041d\u0430\u043c \u0442\u0430\u043a\u0436\u0435 \u043d\u0443\u0436\u043d\u0430 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430, \u043a\u043e\u0442\u043e\u0440\u0430\u044f \u0431\u0443\u0434\u0435\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u043a\u0430\u043a \u0445\u043e\u0441\u0442 \u0434\u043b\u044f Blazor-\u0441\u0442\u0440\u0430\u043d\u0438\u0446. \u0415\u0435 \u043c\u043e\u0436\u043d\u043e \u043d\u0430\u0437\u0432\u0430\u0442\u044c \u043a\u0430\u043a \u0443\u0433\u043e\u0434\u043d\u043e, \u043d\u043e \u0432 \u0448\u0430\u0431\u043b\u043e\u043d\u0430\u0445 Blazor \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f <code>_Host.cshtml<\/code>, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u0432\u043f\u043e\u043b\u043d\u0435 \u043d\u0430\u0441 \u0443\u0441\u0442\u0440\u043e\u0438\u0442 (\u0432\u043f\u0440\u043e\u0447\u0435\u043c, \u043a\u0430\u043a \u0438 \u043b\u044e\u0431\u043e\u0435 \u0434\u0440\u0443\u0433\u043e\u0435). \u0412 <code>_Host.cshtml<\/code> \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u044c \u043c\u0430\u043a\u0435\u0442, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0432 \u043d\u0430\u0448\u0435\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u0431\u0443\u0434\u0435\u0442 \u0442\u0430\u043a\u0438\u043c \u0436\u0435, \u043a\u0430\u043a \u0443 Razor-\u0441\u0442\u0440\u0430\u043d\u0438\u0446.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/sy\/ox\/0n\/syox0n9gussjrle0_4ll8abzgl0.png\"><\/p>\n<p>  <code>_Host.cshtml<\/code> \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0432\u044b\u0437\u043e\u0432 <code>Html.RenderComponentAsync<\/code>:<\/p>\n<p>  <a href=\"https:\/\/mikaelkoskinen.net\/post\/combining-razor-blazor-pages-single-asp-net-core-3-application#\">?<\/a><\/p>\n<pre><code class=\"cs\">@page &quot;\/blazor&quot;   @{     Layout = &quot;_Layout&quot;; }   &lt;app&gt;     @(await Html.RenderComponentAsync&lt;App&gt;(RenderMode.Server)) &lt;\/app&gt;<\/code><\/pre>\n<p>  <b>Startup.cs:<\/b><\/p>\n<p>  \u0418, \u043d\u0430\u043a\u043e\u043d\u0435\u0446, \u043d\u0435\u0431\u043e\u043b\u044c\u0448\u043e\u0435 \u0434\u043e\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u0435 \u043a \u043c\u0435\u0442\u043e\u0434\u0443 <code>Configure Startup.cs<\/code>. \u0420\u0430\u043d\u0435\u0435 \u043c\u044b \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u043b\u0438 <code>MapBlazorHub<\/code>, \u0430 \u0442\u0435\u043f\u0435\u0440\u044c \u043d\u0430\u043c \u043d\u0443\u0436\u043d\u043e \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u0432\u044b\u0437\u043e\u0432 <code>MapFallbackToPage<\/code>, \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u044e\u0449\u0438\u0439 \u043d\u0430 \u043d\u043e\u0432\u044b\u0439 <code>_Host.cshtml<\/code>:<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/xw\/qw\/bd\/xwqwbdcgctl4eotvpsfgb87asjq.png\"><\/p>\n<p>  \u0418 \u043d\u0430 \u044d\u0442\u043e\u043c \u0432\u0441\u0435! \u0422\u0435\u043f\u0435\u0440\u044c \u043d\u0430\u043c \u043f\u0440\u043e\u0441\u0442\u043e \u043d\u0443\u0436\u043d\u043e \u043f\u0440\u043e\u0442\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043d\u0430\u0448 \u0441\u0435\u0442\u0430\u043f. \u0414\u043e\u0431\u0430\u0432\u044c\u0442\u0435 \u0441\u0447\u0435\u0442\u0447\u0438\u043a \u0441\u0442\u0440\u0430\u043d\u0438\u0446 Blazor (Counter) \u0432 \u0441\u0432\u043e\u0439 \u043c\u0430\u043a\u0435\u0442, \u043e\u0442\u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u0432 <code>Pages\/Shared\/_Layout.cshtml<\/code>:<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/f6\/g3\/vp\/f6g3vpodgckmph7o656g3_mpnm4.png\"><\/p>\n<p>  \u041a\u043e\u0433\u0434\u0430 \u043c\u044b \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u043c \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435, \u043c\u044b \u0432\u0438\u0434\u0438\u043c \u0440\u0430\u0431\u043e\u0447\u0443\u044e Blazor-\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0443 \u0432 \u043d\u0430\u0448\u0435\u043c Razor Pages \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0438:<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/dd\/pb\/ao\/ddpbaotumg4us35gdezcwh8wjka.gif\"><\/p>\n<p>  \u0418 \u043c\u044b \u043d\u0435 \u043b\u043e\u043c\u0430\u043b\u0438 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0443 \u0434\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u0438\u044f Blazor-\u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u043e\u0432 \u0432 Razor Pages:<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/vu\/jb\/cn\/vujbcnfwes3zpa1propbz5s4bfa.gif\"><\/p>\n<h3>\u041f\u0440\u0438\u043c\u0435\u0447\u0430\u043d\u0438\u044f<\/h3>\n<p>  \u0421\u043b\u0435\u0434\u0443\u0435\u0442 \u043e\u0442\u043c\u0435\u0442\u0438\u0442\u044c \u043f\u0430\u0440\u0443 \u043c\u043e\u043c\u0435\u043d\u0442\u043e\u0432:<\/p>\n<ul>\n<li>\u041c\u0430\u0440\u0448\u0440\u0443\u0442\u044b Blazor \u0440\u0430\u0431\u043e\u0442\u0430\u044e\u0442 \u0442\u043e\u043b\u044c\u043a\u043e \u0442\u043e\u0433\u0434\u0430, \u043a\u043e\u0433\u0434\u0430 \u043e\u043d\u0438 \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u044e\u0442 \u043d\u0430 \u043a\u043e\u0440\u0435\u043d\u044c. \u0415\u0441\u043b\u0438 \u201c\/counter\u201d \u0438\u0437\u043c\u0435\u043d\u0438\u0442\u044c, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u043d\u0430 <code>\u201c\/products\/counter\u201d<\/code>, \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430 \u043d\u0435 \u0441\u043c\u043e\u0436\u0435\u0442 \u0437\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u044c \u0442\u0440\u0435\u0431\u0443\u0435\u043c\u044b\u0439 <code>blazor.server.js<\/code>. \u0412\u043c\u0435\u0441\u0442\u043e \u044d\u0442\u043e\u0433\u043e \u043c\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u043c 404. \u0414\u043e\u043b\u0436\u043d\u0430 \u0431\u044b\u0442\u044c \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u0438\u0437\u043c\u0435\u043d\u0438\u0442\u044c \u0442\u0435\u0433 script, \u0447\u0442\u043e\u0431\u044b \u043e\u043d \u043c\u043e\u0433 \u0437\u0430\u0433\u0440\u0443\u0436\u0430\u0442\u044c \u0442\u0440\u0435\u0431\u0443\u0435\u043c\u044b\u0439 \u0441\u043a\u0440\u0438\u043f\u0442 \u043d\u0435\u0437\u0430\u0432\u0438\u0441\u0438\u043c\u043e \u043e\u0442 \u043b\u043e\u043a\u0430\u0446\u0438\u0438, \u043d\u043e, \u043f\u043e\u0445\u043e\u0436\u0435, \u044d\u0442\u043e \u0438\u0437\u043c\u0435\u043d\u0438\u043b\u043e\u0441\u044c \u0441 \u043f\u0440\u0435\u0434\u0432\u0430\u0440\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0439 8-\u0439 \u0432\u0435\u0440\u0441\u0438\u0438 \u0432 \u043f\u0440\u0435\u0434\u0432\u0430\u0440\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0439 9-\u0439, \u0438 \u044f \u043d\u0435 \u0441\u043c\u043e\u0433 \u0437\u0430\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0435\u0433\u043e \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c. \u0412\u043e\u0442 \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442 404, \u043f\u043e\u043a\u0430\u0437\u044b\u0432\u0430\u044e\u0449\u0438\u0439 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0443:<img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/0x\/pc\/ns\/0xpcns-fcbznssujmqjlkvjqr18.png\"><\/li>\n<li>\u0415\u0441\u043b\u0438 \u0432\u0430\u043c \u0443\u0434\u0430\u043b\u043e\u0441\u044c \u0437\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u044c \u0441\u043a\u0440\u0438\u043f\u0442, \u0432\u044b, \u0432\u0435\u0440\u043e\u044f\u0442\u043d\u043e, \u0441\u0442\u043e\u043b\u043a\u043d\u0435\u0442\u0435\u0441\u044c \u0441 \u0442\u0435\u043c\u0438 \u0436\u0435 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0430\u043c\u0438 \u0441 Blazor hub: \u0441\u043a\u0440\u0438\u043f\u0442\u044b \u043f\u044b\u0442\u0430\u044e\u0442\u0441\u044f \u043d\u0430\u0439\u0442\u0438 hub \u0432 \/products\/blazor \u0432\u043c\u0435\u0441\u0442\u043e blazor. \u0427\u0442\u043e\u0431\u044b \u043e\u0431\u043e\u0439\u0442\u0438 \u044d\u0442\u043e, \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0432\u0440\u0443\u0447\u043d\u0443\u044e \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u0441\u043e\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u0435 \u043c\u0435\u0436\u0434\u0443 \u0441\u0435\u0440\u0432\u0435\u0440\u043e\u043c \u0438 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u043e\u043c:<\/li>\n<\/ul>\n<p>  <a href=\"https:\/\/mikaelkoskinen.net\/post\/combining-razor-blazor-pages-single-asp-net-core-3-application#\">?<\/a><\/p>\n<pre><code class=\"cs\">&lt;script src=&quot;~\/_framework\/blazor.server.js&quot; autostart=&quot;false&quot;&gt;&lt;\/script&gt; &lt;script&gt;   Blazor.start({     configureSignalR: function (builder) {       builder.withUrl('\/_blazor');     }   }); &lt;\/script&gt;<\/code><\/pre>\n<p>  <\/p>\n<h2>\u041f\u0440\u0438\u043c\u0435\u0440 \u043a\u043e\u0434\u0430<\/h2>\n<p>  <a href=\"https:\/\/github.com\/mikoskinen\/blog\/tree\/master\/blazor-pages-razor-pages-single-app\">\u041f\u0440\u0438\u043c\u0435\u0440 \u043a\u043e\u0434\u0430 \u0434\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043f\u0440\u043e\u0435\u043a\u0442\u0430 \u0434\u043e\u0441\u0442\u0443\u043f\u0435\u043d \u043d\u0430 GitHub<\/a>.<\/p>\n<hr>\n<p>  \u0425\u043e\u0442\u0438\u0442\u0435 \u0443\u0437\u043d\u0430\u0442\u044c \u043e \u043d\u0430\u0448\u0435\u043c \u043a\u0443\u0440\u0441\u0435 \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435? <b><a href=\"https:\/\/otus.pw\/IFnr\/\">\u0412\u0430\u043c \u0441\u044e\u0434\u0430<\/a><\/b>.<\/p>\n<hr>\n<p>  <\/p>\n<h2>\u0427\u0438\u0442\u0430\u0442\u044c \u0435\u0449\u0451:<\/h2>\n<p>  <\/p>\n<ul>\n<li><a href=\"https:\/\/habr.com\/ru\/company\/otus\/blog\/515880\/\">\u0411\u0438\u0442\u0432\u0430 C# JSON \u0441\u0435\u0440\u0438\u0430\u043b\u0438\u0437\u0430\u0442\u043e\u0440\u043e\u0432 \u0434\u043b\u044f .NET Core 3<\/a><\/li>\n<\/ul>\n<p>  <\/p>\n<hr>\n<\/div>\n<p> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/company\/otus\/blog\/516434\/\"> https:\/\/habr.com\/ru\/company\/otus\/blog\/516434\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"\n<div class=\"post__text post__text-html post__text_v1\" id=\"post-content-body\" data-io-article-url=\"https:\/\/habr.com\/ru\/company\/otus\/blog\/516434\/\"><b><i>\u041f\u0435\u0440\u0435\u0432\u043e\u0434 \u0441\u0442\u0430\u0442\u044c\u0438 \u043f\u043e\u0434\u0433\u043e\u0442\u043e\u0432\u043b\u0435\u043d \u0432 \u043f\u0440\u0435\u0434\u0434\u0432\u0435\u0440\u0438\u0438 \u0441\u0442\u0430\u0440\u0442\u0430 \u043a\u0443\u0440\u0441\u0430 <a href=\"https:\/\/otus.pw\/IFnr\/\">\u00abC# ASP.NET Core \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u00bb<\/a>.<\/i><\/b><\/p>\n<hr>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/4l\/5e\/am\/4l5eamg4cnptjngsacl7b_jlgze.png\"><\/p>\n<p>  \u0412 \u044d\u0442\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u044f \u0440\u0430\u0441\u0441\u043a\u0430\u0436\u0443, \u043a\u0430\u043a \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u043d\u0430 \u043e\u0441\u043d\u043e\u0432\u0435 Blazor \u0432 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0435\u0435 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 Razor Pages. <\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/vu\/jb\/cn\/vujbcnfwes3zpa1propbz5s4bfa.gif\"><\/p>\n<h3>\u041f\u0440\u0435\u0434\u0438\u0441\u043b\u043e\u0432\u0438\u0435<\/h3>\n<p>  \u0412\u044b\u0445\u043e\u0434 Blazor \u043d\u0430 \u0437\u043e\u043b\u043e\u0442\u043e <a href=\"https:\/\/www.dotnetconf.net\/\">\u0434\u043e\u043b\u0436\u0435\u043d \u043f\u0440\u043e\u0438\u0437\u043e\u0439\u0442\u0438 \u0447\u0435\u0440\u0435\u0437 \u0434\u0432\u0435 \u043d\u0435\u0434\u0435\u043b\u0438<\/a>. \u041c\u043d\u043e\u0433\u0438\u0435 \u0432\u0435\u0449\u0438 \u0432 \u043f\u0440\u043e\u0435\u043a\u0442\u0435 \u0435\u0449\u0435 \u043f\u043e\u0434\u0432\u0435\u0440\u0436\u0435\u043d\u044b \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0440\u0435\u0437\u043a\u0438\u043c \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u044f\u043c, \u0438 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u044f\u044f \u043f\u0440\u0435\u0434\u0432\u0430\u0440\u0438\u0442\u0435\u043b\u044c\u043d\u0430\u044f 9-\u044f \u0432\u0435\u0440\u0441\u0438\u044f \u0437\u043d\u0430\u0447\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0443\u0441\u043b\u043e\u0436\u043d\u0438\u043b\u0430 \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0435 \u043c\u0435\u0436\u0434\u0443 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u0430\u043c\u0438 Razor Pages \u0438 Blazor: <a href=\"https:\/\/github.com\/aspnet\/AspNetCore\/issues\/13721\">\u0442\u0435\u043f\u0435\u0440\u044c \u043d\u0435\u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e \u043f\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u0442\u044c \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b<\/a> \u0438\u0437 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b Razor \u0432 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442 Blazor \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e<code> Html.RenderComponentAsync<\/code>. \u042d\u0442\u043e \u043c\u043e\u0436\u0435\u0442 \u0438\u0437\u043c\u0435\u043d\u0438\u0442\u044c\u0441\u044f \u0432 \u0431\u0443\u0434\u0443\u0449\u0435\u043c, \u043d\u043e \u0432\u043f\u043e\u043b\u043d\u0435 \u0432\u0435\u0440\u043e\u044f\u0442\u043d\u043e, \u0447\u0442\u043e \u0432 .NET Core 3.0 \u043e\u043d \u043f\u043e\u044f\u0432\u0438\u0442\u0441\u044f \u0441 \u044d\u0442\u0438\u043c \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u0438\u0435\u043c.<\/p>\n<p>  \u0415\u0441\u043b\u0438 \u0432\u044b \u0432\u0441\u0435 \u0436\u0435 \u0445\u043e\u0442\u0438\u0442\u0435 \u0443\u043b\u0443\u0447\u0448\u0438\u0442\u044c \u0441\u0432\u043e\u0435 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0435\u0435 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u043d\u0430 \u043e\u0441\u043d\u043e\u0432\u0435 Razor Pages \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e Blazor-\u043c\u0430\u0433\u0438\u0438, \u043e\u0434\u043d\u043e \u0438\u0437 \u0440\u0435\u0448\u0435\u043d\u0438\u0439 \u2014 \u043f\u043e\u043b\u043d\u043e\u0441\u0442\u044c\u044e \u0441\u043e\u0437\u0434\u0430\u0432\u0430\u0442\u044c \u0441\u0432\u043e\u0438 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u0432 Blazor. \u0412 \u044d\u0442\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u044f \u043f\u043e\u043a\u0430\u0436\u0443, \u043a\u0430\u043a \u0432\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0442\u044c Blazor-\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u0432 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0435\u0435 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u043d\u0430 \u043e\u0441\u043d\u043e\u0432\u0435 Razor Pages, \u0433\u0434\u0435 \u043e\u0434\u043d\u0438 \u0447\u0430\u0441\u0442\u0438 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u0441\u043e\u0437\u0434\u0430\u044e\u0442\u0441\u044f \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e Razor Pages, \u0430 \u0434\u0440\u0443\u0433\u0438\u0435 \u2014 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e Blazor Pages. \u0414\u043b\u044f \u043e\u0431\u043e\u0438\u0445 \u0442\u0438\u043f\u043e\u0432 \u0441\u0442\u0440\u0430\u043d\u0438\u0446 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f <b>\u043e\u0434\u0438\u043d\u0430\u043a\u043e\u0432\u044b\u0439 \u043c\u0430\u043a\u0435\u0442.<\/b><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-308943","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/308943","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=308943"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/308943\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=308943"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=308943"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=308943"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}