Skip to content
Blazor University
Learn the new .NET SPA framework from Microsoft
Search for
Search
Menu
Search Results
Introduction
What is Blazor?
What is WebAssembly?
Blazor hosting models
Installing Blazor
Creating a new project
Creating a page
Layouts
Creating a Blazor layout
Using a layout
Nested layouts
Components
Creating a component
One-way binding
Literals, expressions, and directives
Directives
Component events
Browser DOM events
Two-way binding
Binding directives
Cascading values
Cascading values by name
Cascading values by type
Overriding cascaded values
Code generated HTML attributes
Capturing unexpected parameters
Replacing attributes on child components
Component lifecycles
Creating components with Generics
Code-behind
Multi-threaded rendering
Thread safety using InvokeAsync
Render trees
Incremental RenderTree proof
Optimising using @key
Templating components with RenderFragments
Creating a TabControl
Passing data to a RenderFragment
Using @typeparam to create generic components
Passing placeholders to RenderFragments
Routing
Defining routes
Route parameters
Constraining route parameters
Optional route parameters
404 – Not found
Navigating our app via HTML
Navigating our app via code
Detecting navigation events
Forms
Editing form data
Descending from InputBase<T>
Validation
Accessing form state
Handling form submission
EditContext, FieldIdentifiers, and FieldState
Writing custom validation
Component libraries
JavaScript interop
JavaScript boot process
Calling JavaScript from .NET
Updating the document title
Passing HTML element references
Calling .NET From JavaScript
Lifetimes and memory leaks
Type safety
Calling static .NET methods
Dependency injection
Injecting dependencies into Blazor components
Dependency lifetimes and scopes
Transient dependencies
Singleton dependencies
Scoped dependencies
Comparing dependency scopes
Component scoped dependencies
OwningComponentBase<T>
Owning multiple dependencies: The wrong way
Owning multiple dependencies: The right way
Terms of service
Creating components with Generics
What is Blazor?