How-To: Add Blazor Component Interactivity with One-Way Binding

Building a static HTML page with Blazor is pretty easy, but doesn't make for an interesting application. To support basic interactivity, Blazor components/pages use databinding to show dynamic data and respond to events on the component and its elements. The simplest form of databinding is one-way binding. One-way binding renders the data from our code … Continue reading How-To: Add Blazor Component Interactivity with One-Way Binding

How-To: Write First bUnit Test

bUnit is a testing library for Blazor components. Its goal is to make it easy to write comprehensive, stable unit tests for these components. We will learn the steps to create our first bUnit test from setup to rendering to validation. This first test will be very simple to allow us to focus on the mechanics of creating the … Continue reading How-To: Write First bUnit Test

How-to: Add bUnit Test Project to Blazor Solution

Having automated tests for our Blazor applications is very important. We can use xUnit (or any other) test framework to write unit tests for the C# classes in our app. However, some part of our logic (even if it's just the databinding logic) lives in Blazor components and pages. For those to be tested, we … Continue reading How-to: Add bUnit Test Project to Blazor Solution