File Dropzone

Svelte Component

Allow upload of files with drag and drop.

Examples

Monitor your browser's console when adding files.

Usage

Uses input[type='file'] to allow for all native input accessibility.

ts
let files: FileList;
html
<FileDropzone bind:files />

Notes

Use the notes property to provide addition text information on a second line.

html
<FileDropzone notes="Files should not exceed 5mb." />

Message

Use the default slot to replace the default UI entirely.

html
<FileDropzone>(message)</FileDropzone>