https://github.com/viewstools/animations
Views animations wrapper around react-spring
https://github.com/viewstools/animations
Last synced: 12 months ago
JSON representation
Views animations wrapper around react-spring
- Host: GitHub
- URL: https://github.com/viewstools/animations
- Owner: viewstools
- Created: 2018-07-06T16:19:29.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2018-10-24T19:12:52.000Z (over 7 years ago)
- Last Synced: 2025-06-06T04:45:27.308Z (about 1 year ago)
- Language: JavaScript
- Size: 29.3 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# @viewstools/animations
Animations wrapper around [react-spring](https://github.com/drcmda/react-spring)
with an API closer to what Views would use internally.
For React DOM we only expose a `Spring` component as in Views we do timing animations through CSS.
Use it like:
```
import { Spring } from '@viewstools/animations/dom'
{
styles => (
//... do something with the styles object it will have the updated
// paddingTop value
)
}
```
For React Native we expose a `Spring` and `Timing` instead. Spring is the same
interface that DOM has -just import it from `@viewstools/animations/native`.
Use `Timing` like:
```
import { Timing } from '@viewstools/animations/native'
{
styles => (
//... do something with the styles object it will have the updated
// paddingTop value
)
}
```
License MIT.
(c) 2018 UXtemple Ltd.