qrcode-scanner-svelte
TypeScript icon, indicating that this package has built-in type declarations

1.0.0 • Public • Published

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>

/qrcode-scanner-svelte/

    Package Sidebar

    Install

    npm i qrcode-scanner-svelte

    Weekly Downloads

    3

    Version

    1.0.0

    License

    none

    Unpacked Size

    22.9 kB

    Total Files

    22

    Last publish

    Collaborators

    • douganderson444