title: Error in react-spring with typescript for react
body: <p>I'm trying to make an animation using react-spring, but when I go to call the useTransition function passing the properties of some kind of errors I'm not understanding</p>
  <pre><code>import React from 'react';
  import { useTransition } from 'react-spring';
  import { Container } from './styles';
  import { ToastMessage } from '../../hooks/toast';
  import Toast from './Toast/index';
  
  interface ToastContainerProps {
    messages: ToastMessage[];
  }
  
  const ToastContainer: React.FC&lt;ToastContainerProps&gt; = ({ messages }) =&gt; {
    const messageWithTransitions = useTransition(
      messages,
      message =&gt; message.id,
      {
        from: { right: '-120%' },
        enter: { right: '0%' },
        leave: { right: '-120%' },
      },
    );
    return (
      &lt;Container&gt;
        {messageWithTransitions.map(({ item, key, props }) =&gt; (
          &lt;Toast key={key} message={item} /&gt;
        ))}
      &lt;/Container&gt;
    );
  };
  
  export default ToastContainer;
  
  </code></pre>
  <p>Error:</p>
  <p>No overload matches this call.
  Overload 1 of 3, '(data: OneOrMore, props: () =&gt; { ref?: SpringRef&lt;Lookup&gt; | undefined; from?: TransitionFrom; ... 23 more ...; onDestroyed?: ((item: ToastMessage, key: Key) =&gt; void) | undefined; } | (object &amp; {}), deps?: any[] | undefined): [...]', gave the following error.
  Argument of type '(message: any) =&gt; any' is not assignable to parameter of type '() =&gt; { ref?: SpringRef&lt;Lookup&gt; | undefined; from?: TransitionFrom; loop?: LoopProp&lt;ControllerUpdate&lt;Lookup, undefined&gt;&gt; | undefined; ... 22 more ...; onDestroyed?: ((item: ToastMessage, key: Key) =&gt; void) | undefined; } | (object &amp; {})'.
  Overload 2 of 3, '(data: OneOrMore, props: { ref?: SpringRef&lt;Lookup&gt; | undefined; from?: TransitionFrom; ... 23 more ...; onDestroyed?: ((item: ToastMessage, key: Key) =&gt; void) | undefined; } | (object &amp; {}), deps: any[] | undefined): [...]', gave the following error.
  Argument of type '{ from: { right: string; }; enter: { right: string; }; leave: { right: string; }; }' is not assignable to parameter of type 'any[]'.
  Object literal may only specify known properties, and 'from' does not exist in type 'any[]'.  TS2769</p>
  <pre><code> const ToastContainer: React.FC&lt;ToastContainerProps&gt; = ({ messages }) =&gt; {
  const messageWithTransitions = useTransition(
                                     ^
       messages,
      message =&gt; message.id,
  </code></pre>