Комментарии:
You have to wonder why Microsoft would release something so broken, it's like they released it hoping no one would notice the obvious flaw. In short interactive modes don't work without being hacked which in turn creates problems elsewhere in your application.
ОтветитьMS did not handle this feature well. The syntax is a mess, changed right before release, and they seem to have not bothered to prepare people for it with sufficient docs and examples. When the actual template sample page (Weather) displays the problematic behavior and doesn’t offer a fix, that’s quite an oversight.
ОтветитьI would add that the rendermode is inherited by all components unless otherwise specified in the component itself. Nonetheless I would have added the ability to disable it at the assemplies level. Something like app.MapRazorComponents<App>()
.AddInteractiveWebAssemblyRenderMode()
.AddAdditionalAssemblies(typeof(Counter).Assembly, prerendering: false);
Thank you Patrick for this timely tutorial !
ОтветитьYikes...these comments are harsh. Lol. For me, the positives far outweigh the negatives with Balzor 8.
They packed a LOT in this release so some combinations or features have questionable defaults...ok.
With the alternatives of waiting till .NET 9, I think they made a great call.
Thanks for the video,
You could possibly solve the problem by using a persistent state provider to store the loaded data from the prerendering and then load that same data when the interactivity hits.
not useful in this weather page case but could be a good thing when SEO is needed but you dont want to load the data from the database twice.
maybe a good video idea to explore the persistent state provider?
Thanks for the great video! Couple of questions here.
First, what's the situation where you do want pre-render? It's the default option, so I'm assuming they thought most pages would use it? But this data-fetching problem would be incredibly common I would think
Second, I don't understand how to juggle the webassembly and SSR. Here you have the same weather page on both WASM and SSR. But what if you want to mix them? It seems weird to me that we have to do a websocket roundtrip request to change state on the server, when it's something like toggling a button that only matters on the frontend.
Hi, with .net8 new architecture in blazor web app.. where we put custom javascript? in Server project or Client project?
Ответитьhow to use Crystal Reports with Blazor
ОтветитьExample Selenium automatic unit test
ОтветитьSo good videos, I just found your channel! The ability to keep advanced and broad koncepts simple brings so much quality. This has helped me alot were i needed to transition to Angular within my job. If I were to make a request, I would love to see an updated version of a simple .NET project with an Angular client. It would be valuable to see such a project now that Angular's latest version includes new control flow, standalone components, and signals!
ОтветитьWill you update your E-Commerce Website with Blazor WebAssembly at some point?
I know it's a time issue, so I'm just asking!
Hi Patrick, I'm new to your channel and the Blazor world. Great content! Hoping you can answer this question - regardless of the rendering mode, I've noticed when you Network > Preview, that there is "An unhandled error has occurred. Reload" message, which is hidden from the user. Does anyone know what is the cause of this and how to fix?
ОтветитьThis concept doesn't seem to stick for me. I am unsure whether to build with Server, WASM, or AUTO.
ОтветитьI'm becoming a big fan of your channel Patrick. Thanks for sharing your vast knowledge.
ОтветитьI wish you could tell something about preparing Blazor page for SEO.
I assume it has something in common with rendermode's 'first load'.
@PatrikGod In this mode the PageTitle not showing, did you notice that??
ОтветитьThanks Patrick for the video.
Could you make a video showing hot to use local storage with blazor 8?
Unfortunately, as you've mentioned in the video, disabling/bypassing Pre-rendering harms SEO and prevents search engines from seeing/indexing page content, even though the solution is useful from a UX point of view.
I eventually had to re-enable it because search engines saw pages as empty.
Are you aware of a better solution that still allows prerendering to remain enabled?
Thanks, saved me having to work out what this was, well explained, I've been using Blazor for a few years now, sometimes forget to look at new features
ОтветитьHi Patrick. Thank you so much for the tip. Appreciate it !
ОтветитьHi Patrick, love your teaching approach, thank you so much.
ОтветитьJust what I needed! 🙏
ОтветитьSoooo Helpful!! Thanks a lot
Ответить