Heron.BlazorQRScanner
1.0.2
dotnet add package Heron.BlazorQRScanner --version 1.0.2
NuGet\Install-Package Heron.BlazorQRScanner -Version 1.0.2
<PackageReference Include="Heron.BlazorQRScanner" Version="1.0.2" />
paket add Heron.BlazorQRScanner --version 1.0.2
#r "nuget: Heron.BlazorQRScanner, 1.0.2"
// Install Heron.BlazorQRScanner as a Cake Addin #addin nuget:?package=Heron.BlazorQRScanner&version=1.0.2 // Install Heron.BlazorQRScanner as a Cake Tool #tool nuget:?package=Heron.BlazorQRScanner&version=1.0.2
Heron.BlazorQRScanner
A simple QR code scanner for Blazor.
The project is basically just a wrapper around the jsQR javascript library.
Getting Started
Install the Heron.BlazorQRScanner package.
dotnet add package Heron.BlazorQRScanner
Add the following to _Imports.razor
.
@using Heron.BlazorQRScanner
Usage
The component has 2 properties AutoStart
and AutoStop
which are both true by default. This means you can simply
place the Scanner
component on a page and the camera will be opened and scanning started as soon the page is opened.
Scanning will stop as soon as a QR Code is found.
A simple implementation looks like this
@if (string.IsNullOrEmpty(_code))
{
<Scanner CodeFound="CodeFound" />
}
else
{
<div>
Code = @_code
</div>
}
@code
{
private string _code = string.Empty;
private void CodeFound(string code)
{
_code = code;
}
}
Alternatively starting and stopping scanning can be done by calling the Start
and Stop
methods on the component.
Support
For any issues or feature requests, please open a new issue on GitHub.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. |
-
net8.0
- Microsoft.AspNetCore.Components.Web (>= 8.0.11)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last updated |
---|---|---|
1.0.2 | 111 | 12/11/2024 |
1.0.1 | 114 | 11/11/2024 |
1.0.0 | 103 | 10/3/2024 |
1.0.0-beta.1 | 69 | 6/7/2024 |