It seems like it's because there's been zero documentation on it?
How am I supposed to find out about this library and that it can be used in regular React? When I search for "react animated" the only official docs I get are https://facebook.github.io/react/docs/animation.html, which are now deprecated and have no relation to react-native-animated.
The official documentation for react-native-animated at https://facebook.github.io/react-native/docs/animated.html don't mention anything about web components (eg. Animated.div) -- they only mention native components: https://facebook.github.io/react-native/docs/animated.html#a...
So I guess my questions are: how do I find out about regular, official React libraries like this? And how do I know this isn't an internal library that won't be changed at some point?
In the webpackbin it demonstrates the use if you want to test it. You install it with: npm install animated --save
['red', 'blue', 'yellow'].find((d, i) => i === Math.round(Math.random() * 2))
`Math.round(Math.random() * 2)` might produce the following sequence: 2, 2, 0. The find callback is called with 0, 1, 2, so it returns nothing.
Maybe they were going for:
['red', 'blue', 'yellow'][Math.round(Math.random() * 2)]
['red', 'blue', 'yellow', null][Math.round(Math.random() * 3)]
`|0` is a good trick, I'll have to remember that.
I wouldn't recommend using this unless you're trying to shove milliseconds in this type of operations.
This sort of declarative transition comes in handy for us all the time. Two features I don't see yet in React-Move that we find useful is a prop for more precise control over the staggering (orderBy), and custom interpolation (interpolate).
(an aside, but boasting about a 12KB minified size for an animation library baffles me. That's huge!)
Use the d3 stuff directly, or a good tweening library that is well-suited and hardware accelerated for your platform.
If all of these amazing features aren't your cup of tea, then I would most definitely suggest that you roll your own solution. :)
Feel free to wire together your own solution if that works better for you. As for me, react-move is exactly what I need.
It's certainly an evolving product and not every native function (such as video recording) is available as an easy-to-use component. In those cases, you can use a 3rd party NPM component or write your own Java/ObjC and link it in with your own custom component. Even if you have to write a little bit of Java/ObjC, it's a huge time saver.
Animation stuff in Redux state would not be as nice.