Skip to content

michaeljonathanblack/react-phazy

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

react-phazy

A progressive, lazy-loading image-loader for React, with the canvas Blur effect popularized by Medium

It's a bunch of totally competent libraries plainly stitched together because I've read a handful of articles on how to build what Medium built, but no one had the common decency to publish an npm package.

This project's examples were bootstrapped with Create React App.

Installation

npm install react-phazy --save

Usage

Provide a high resolution source image, its width and height, and a very small preview image and you're off to the races. The alt text is also required because we're not monsters.

<Phazy
  source={source}
  preview={preview}
  alt={alt}
  width={width}
  height={height}
/>

Required styles are available in App.css under .phazy

Demo

yarn
yarn start

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published