Next Placeholder Versions Save

Beautiful image placeholders, without the hassle.

v3.0.0

11 months ago

[email protected]: Final Release

Note

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 ๐Ÿ–ค

Features

  • New color return for getting an image's "dominant" color
  • New pixels return for getting each raw pixel's rgba values
  • Transparent images no longer have their alpha channel removed by default
  • Support for EXIF orientation (via autoOrient option)
  • New and improved docs

Breaking Changes

Read the migration guide for further information.

  • ESM only
  • File paths or external URLs are no longer supported โ€“ getPlaiceholder now expects a Buffer (see the migration guide for examples)
  • blurhash no longer returned
  • img โ†’ metadata

Note

If no major issues are reported in the coming weeks, this repository will be archived and issues closed.

v2.5.0

1 year ago

It's a big one! ๐Ÿš€

Announcements

Plaiceholder's hosting is now fully sponsored by @vercel ๐Ÿ–ค

Huge thanks to @leerob for sorting this out

Features

Docs & Examples

Full Changelog: https://github.com/joe-bell/plaiceholder/compare/v2.4.0...v2.5.0

v2.4.0

1 year ago

What's Changed

Internal

New Contributors

Full Changelog: https://github.com/joe-bell/plaiceholder/compare/v2.3.0...v2.4.0

v2.3.0

2 years ago

What's Changed

Lots of security bumps ๐Ÿ”’

Full Changelog: https://github.com/joe-bell/plaiceholder/compare/v2.2.0...v2.3.0

v2.2.0

2 years ago

Features

  • @plaiceholder/next: add support for Next.js 12 (thanks @JeromeFitz!)

Bug Fixes

  • Miscellaneous security updates for dependencies

v2.1.0

2 years ago

Features

v2.0.3

2 years ago

Bug Fixes

  • @plaiceholder/next: add sharp to webpack externals (76a49be)

v2.0.2

2 years ago

Bug Fixes

  • @plaiceholder/tailwindcss: lock Tailwind peerDependency range (due to reliance on experimental JIT engine) (08a1760)

v2.0.1

2 years ago

Bug Fixes

  • plaiceholder: add missing return types (e434e63)

v2.0.0

2 years ago

Key Changes

  • ๐Ÿ”ฅ 90% less CSS by default
  • ๐ŸŒ Remote image support
  • ๐Ÿ“ Size customisation
  • ๐Ÿงน Improvements to DX and docs
  • ๐Ÿ†• A brand new Tailwind JIT plugin

See the new plaiceholder.co/docs for more

Migration

@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");