paste-rich
p/paste-rich
Smart clipboard paste handler. Normalizes paste events
0 reviews3 followers
Start new thread
trending
Ronak Bhandari

13d ago

paste-rich - Smart clipboard paste handler. Normalizes paste events

Handling paste events in the browser is deceptively complex. Screenshots paste as image/png blobs. Word documents include both HTML and plain text. File explorers inject DataTransferItem lists. Every app — Notion clones, WYSIWYG editors, comment boxes — ends up writing its own clipboardData parsing from scratch. paste-rich normalizes paste events into predictable types — image, file, HTML, or text — in 3 lines. Zero dependencies. One callback, one predictable shape: { type, data, files }.