Architecture

This help article describes the structure and architecture of the typical Radzen Blazor application.

Project structure

The Radzen Blazor application has two top-level directories:

meta
server

The meta directory contains JSON files that describe the application structure - data sources, pages, assets.

Blazor project

The server directory contains the server-side Blazor application. Radzen generates the contents of the server directory from the JSON files found in the meta directory.

server
Startup.cs
Data
NorthwindContext.cs
Models
Northwind
Product.cs
Pages
Products.razor
Products.razor.cs
Products.razor.designer.cs
Services
NorthwindService.cs

The server\Data directory contains Entity Framework Core context classes. Radzen uses Entity Framework Core to connect to databases.

The server\Models directory contains model classes generated from the application data sources - database tables, REST responses etc.

The server\Pages directory contains Razor pages which Radzen has generated.

  1. <page-name>.razor - the page markup - HTML and Blazor tags. This file is generated every time you run the application for Radzen. Any changes made to this file will be overwritten.
  2. <page-name>.razor.cs - C# partial class that is empty by default. This file is generated only once. Used for custom code.
  3. <page-name>.razor.designer.cs - C# class that implements the Blazor component - handles UI component events (e.g. button clicks), loads data, etc. This file is generated every time you run the application for Radzen. Any changes made to this file will be overwritten.

The server\Services directory contains service classes that communicate with a data source.

Most of the generated classes are partial (EF contexts, models, services and pages). You can use partial methods to customize the default behavior. More info is available in the customization article.

FAQ

Here is a quick FAQ regarding Blazor support in Radzen:

Does Radzen support client-side or server-side Blazor?

Radzen supports server-side Blazor applications.

Can I migrate my existing Radzen Angular application to Blazor?

Not automatically. Radzen can still scaffold the same database and create a fully working Blazor application.

What UI components are you using in Radzen Blazor applications?

We are developing a brand new suite of native Blazor components. Native means that we don’t wrap existing JS libraries - everything is 100% Blazor code compatible with Blazor data-binding, templates and event handling.

When will component X be available in Radzen Blazor applications?

We will gradually implement the remaining components from the Radzen toolbox.

We are here for you

Making our users happy is always a priority for us.