Create A Toast Component In A Blazor Server Application
Blazor Toast is a small, nonblocking notification pop-up. This is a quick-start project provided by Syncfusion to help you create a Blazor Toast. This example explains how to create a Blazor application and add the Syncfusion Blazor package. It also shows how to add the Syncfusion Blazor Toast component to a Blazor server application, position the Toast, timeout, and render the toast content using an HTML template.
Watch a How-to Video: https://www.syncfusion.com/tutorial-videos/blazor/toast?title=create-a-toast-component-in-a-blazor-server-application
Prerequisites
- Visual Studio 2022
How to run the project
- Checkout this project to a location in your disk.
- Open the solution file using the Visual Studio 2022.
- Restore the NuGet packages by rebuilding the solution.
- Run the project.
Further help
For more help, check the ASP.NET Core Blazor documentation.
Features and benefits
Positioning notifications
The Blazor toast notifications component is easily positioned wherever you want using built-in positions or custom axis values (X and Y).
Animation
Users can configure different animations to show or hide the toast, and can configure the animation duration based on the content length of the notification message and reading time.
Dismiss toasts
Users can dismiss all Blazor toast notification messages through user input or time-outs. Or they can be dismissed by swiping or tapping on notifications.
Toast message types
Users can easily design common Blazor toast notifications using built-in classes such as success, warning, information, and error.
Timing (duration)
The Blazor toast notification component can be configured with a duration time for the complete message to be read in before it is hidden. You can extend the timeout dynamically after focusing on it.
Progress bar
Users can enable a progress bar inside the toast to track the progress of an operation and the expiration of a toast message.
Toast message validation
Users can validate duplicate toast notifications and allow only distinct toast messages on the screen. They can restrict the maximum number of toasts that are displayed. Also, users can prevent toast messages from hiding and make them stick with the screen.
Related links
Suggest a feature or report a bug
About Syncfusion Blazor Components
The Syncfusion's Blazor components library offers over 70 UI components to work with Blazor server-side and client-side (Blazor WebAssembly) projects seamlessly. In addition to Toast, we provide popular Blazor Components such as DataGrid, Charts, Scheduler, Diagram, and Word Processor.
About Syncfusion
Founded in 2001 and headquartered in Research Triangle Park, N.C., Syncfusion has more than 28,000 customers and more than 1 million users, including large financial institutions, Fortune 500 companies, and global IT consultancies.
Today, we provide 1700+ components and frameworks for web (Blazor, ASP.NET Core, ASP.NET MVC, ASP.NET WebForms, JavaScript, Angular, React, Vue, and Flutter), mobile (Xamarin, Flutter, UWP, JavaScript, and .NET MAUI), and desktop development (WinForms, WPF, WinUI, Flutter, UWP, and .NET MAUI). We provide ready-to-deploy enterprise software for dashboards, reports, data integration, and big data processing. Many customers have saved millions in licensing fees by deploying our software.
[email protected] | www.syncfusion.com | Toll Free: 1-888-9 DOTNET