Cascading Dropdowns & SEO with Blazor 🔍


Hey Reader,

This week, I'm diving into a couple of topics that have been popping up frequently in your questions. I hope you'll find the insights below helpful!

🛠️Cascading Dropdowns

Did you know there's no built-in component in Blazor for dropdowns that update based on another dropdown's selection? No worries - I’ve got you covered! Check out the video below where I show you how to build your own.

video preview

The key is to use the standard HTML select element instead of Blazor’s InputSelect. Then, harness the power of the relatively new @bind:after directive to trigger a specific method whenever a dropdown’s value changes. This technique is super versatile and can be applied to more than just dropdowns.

🔍 SEO with Blazor

There's a common misconception that Blazor doesn't play well with SEO, similar to other SPA frameworks. But with the release of .NET 8, that's simply not the case anymore! By default, Blazor now uses SSR (static server-side rendering), which means all content is rendered on the server before reaching the client. This allows search engines and crawlers to see the actual content of a page. Plus, pre-rendering is enabled for other rendering modes by default. Curious about how each rendering mode works with SEO? I've got a detailed video breakdown just for you below.

video preview

If you have more questions or need further clarification, just hit reply to this email. I’m here to help with more tutorials and to answer all your queries.

A massive thank you to our community and my Patrons for your support. You are the backbone of this newsletter and my YouTube channel. Stay safe!

Take care & happy coding,

Patrick


Patrick God

Become a .NET & Blazor expert with weekly tutorials featuring best practices and the latest improvements, right in your inbox.

Read more from Patrick God
video preview

Hey Reader, After 15 years of building web apps, I just recently discovered Vertical Slice Architecture. I know. I’m late to the party. But wow, this approach really changed how I think about structuring Blazor projects. So I decided to show you a simple, real-world example of how to use Vertical Slice Architecture in a Blazor Server app. 🎥 Watch the full tutorial now: In this new tutorial, you'll learn: ✅ How to structure your app with feature folders ✅ How to avoid overcomplicating things...

video preview

Hey Reader, In my last videos, we built a solid CRUD API using Vertical Slice Architecture, Minimal APIs, and Carter - super clean and modern. But there’s still one problem... 👉 What happens when a user sends empty or invalid data? In this new YouTube tutorial, I’ll show you how to fix that with: And yep, the full source code is free to download. Just check the link in the video description. If you’ve been enjoying this Vertical Slice series, this is a must-watch. It’s a simple upgrade that...

video preview

Hey Reader, If you're building apps with Blazor, you've probably asked yourself this: 👉 Should I use SSR, Blazor Server, or WebAssembly? It’s a common question - and I get it a lot. So I made a brand-new YouTube video walking you through how to choose the best one for your app. 🎥 Watch it here: If you're building a Blazor app or planning to do so soon, this should help clear up a lot of confusion. Let me know what you think, and feel free to reply if you have any questions. Take care, Patrick...