Closed Gander7 closed 5 years ago
Hi,
can you please try to install the library using the command
dotnet add package Sotsera.Blazor.Toaster --version 1.0.0-preview.8.1
?
I must update the installation instructions in the readme because the last library version is considered a prerelease and the command you used installs the last available release. Thanks for the heads up.
Works :) Thanks for the quick reply, this is a great resource.
The only other thing missing from the readme is a mention to add using using Sotsera.Blazor.Toaster.Core.Models;
to Startup.cs for the Dependency injection configuration portion.
@Gander7 Sorry for the late response. I added the using
reference to the readme. Thanks for the suggestion!
This is an awesome toast, unfortunately I'm having issues getting it to work via a package :(
dotnet --version ->
3.0.100-preview8-013656
Followed readme instructions for serverside:
dotnet add package Sotsera.Blazor.Toaster
<link href="_content/Sotsera.Blazor.Toaster/toastr.min.css" rel="stylesheet" />
to Hostusing using Sotsera.Blazor.Toaster.Core.Models;
to Startup for Defaults<ToastContainer />
and using to MainLayout[Inject]
to code-behind class of a pageprotected void ShowToast()
method to code-behind class with a body ofToaster.Info("toast body text");
No Build/Compiler Errors. Runtime error on run:
Raw Error: https://pastebin.com/R5D4aubU
I was able to replicate using a new project (
dotnet new blazorserver
).