1.0.7 • Published 2 years ago

@peerpiper/qrcode-scanner-svelte v1.0.7

Weekly downloads
-
License
-
Repository
github
Last release
2 years ago

PWA QR Code Scanner

QR Code scanner in a Svelte Component

Use

Demo

Basic

<Scanner />

Custom

    let result

    <Scanner bind:result>
        <!-- Insert custom results component if you want to do something unique with the QR code data -->
		<!-- override default by placing handler in here  -->
		{#if result}
			<div>
				The result is: {result}
			</div>
			<div>
				<button on:click={() => (result = null)}>Scan again</button>
			</div>
		{/if}
	</Scanner>