Beautiful image placeholders, without the hassle.
[email protected]
: Final ReleaseNote
The
plaiceholder
project is feature complete and will now be kept in maintenance mode.Read the migration guide for further information.
If this project has been useful to you, please consider sponsoring my work ๐ค
color
return for getting an image's "dominant" colorpixels
return for getting each raw pixel's rgba
valuesalpha
channel removed by defaultautoOrient
option)Read the migration guide for further information.
getPlaiceholder
now expects a Buffer
(see the migration guide for examples)blurhash
no longer returnedimg
โ metadata
Note
If no major issues are reported in the coming weeks, this repository will be archived and issues closed.
It's a big one! ๐
Plaiceholder's hosting is now fully sponsored by @vercel ๐ค
Huge thanks to @leerob for sorting this out
./public
Full Changelog: https://github.com/joe-bell/plaiceholder/compare/v2.4.0...v2.5.0
sharp
to @plaiceholder/tailwindcss
's peerDependencies
by @joe-bell in https://github.com/joe-bell/plaiceholder/commit/adf88de63fd1515cafbb2de4f4c30fb35393042b
Full Changelog: https://github.com/joe-bell/plaiceholder/compare/v2.3.0...v2.4.0
Lots of security bumps ๐
Full Changelog: https://github.com/joe-bell/plaiceholder/compare/v2.2.0...v2.3.0
See the new plaiceholder.co/docs for more
@plaiceholder/css
-- import { getPixelsCSS } from "@plaiceholder/css";
-- import { getImage } from "@plaiceholder/next";
--
-- const src = "/assets/images/preview/preview.jpg";
-- const img = await getImage(src);
-- const pixelsCSS = await getPixelsCSS(img);
++ import { getPlaiceholder } from "plaiceholder";
++ const { css } = getPlaiceholder("/assets/images/preview/preview.jpg");
@plaiceholder/svg
-- import { getPixelsSVG } from "@plaiceholder/svg";
-- import { getImage } from "@plaiceholder/next";
--
-- const src = "/assets/images/preview/preview.jpg";
-- const img = await getImage(src);
-- const pixelsSVG= await getPixelsSVG(img);
++ import { getPlaiceholder } from "plaiceholder";
++ const { svg } = getPlaiceholder("/assets/images/preview/preview.jpg");
@plaiceholder/base64
-- import { getBase64 } from "@plaiceholder/base64";
-- import { getImage } from "@plaiceholder/next";
--
-- const src = "/assets/images/preview/preview.jpg";
-- const img = await getImage(src);
-- const base64= await getBase64(img);
++ import { getPlaiceholder } from "plaiceholder";
++ const { base64 } = getPlaiceholder("/assets/images/preview/preview.jpg");
@plaiceholder/blurhash
-- import { getBlurhash } from "@plaiceholder/blurhash";
-- import { getImage } from "@plaiceholder/next";
--
-- const src = "/assets/images/preview/preview.jpg";
-- const img = await getImage(src);
-- const blurhash= await getBlurhash(img);
++ import { getPlaiceholder } from "plaiceholder";
++ const { blurhash } = getPlaiceholder("/assets/images/preview/preview.jpg");