0.2.3 • Published 3 years ago

react-spring-animated-grid v0.2.3

Weekly downloads
6
License
MIT
Repository
github
Last release
3 years ago

react-spring-animated-grid

Animated grid responsive to width changes.

Features

  • Width aware animated reordering elements

Install

npm i react-spring-animated-grid

Preview

example

Usage

import { GridComponent } from 'react-spring-animated-grid'
...
<GridComponent itemMarginRight={10} style={{ width: "300px" }}>
  {elements.map((e, i) => (
    <div
      className="item"
      key={e.text}
      onClick={() => toggleClicked(e.text)}
    >
      {!isClicked(e.text) && e.text}
    </div>
  ))}
</GridComponent>

Demo

https://codesandbox.io/s/animated-grid-demo-ycu8x?file=/src/App.js:793-814

0.2.3

3 years ago

0.2.2

3 years ago

0.2.1

3 years ago

0.2.0

3 years ago

0.1.0

3 years ago