Svelte component for blurhash images.
npm install -D blurhash-svelte
The package includes two components:
Component for rendering a blurhash image as placeholder while image loads.
import { BlurHashImage } from 'blurhash-svelte'
<BlurHashImage
height={128}
width={128}
punch={1}
src={"<YOUR-IMAGE-SRC>"}
hash={"<YOUR-BLURHASH-STRING>"}
useLazy={true}
>
Component for rendering only the blurhash image.
import { BlurHash } from 'blurhash-svelte'
<BlurHash
height={128}
width={128}
punch={1}
hash={"<YOUR-BLURHASH-STRING>"}
>