@img-comparison-slider/react
TypeScript icon, indicating that this package has built-in type declarations

8.0.2 • Public • Published

ImgComparisonSlider

npm package

React wrapper for img-comparison-slider component.

Usage examples: https://img-comparison-slider.sneas.io/examples.html

Example

Installation

yarn add @img-comparison-slider/react

Usage

import { ImgComparisonSlider } from '@img-comparison-slider/react';

// ...
render() {
  return (
    <ImgComparisonSlider>
      <img slot="first" src="https://img-comparison-slider.sneas.io/demo/images/before.webp" />
      <img slot="second" src="https://img-comparison-slider.sneas.io/demo/images/after.webp" />
    </ImgComparisonSlider>
  );
}

Readme

Keywords

none

Package Sidebar

Install

npm i @img-comparison-slider/react

Weekly Downloads

9,894

Version

8.0.2

License

MIT

Unpacked Size

7.47 kB

Total Files

5

Last publish

Collaborators

  • sneasio