mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2025-10-16 12:05:41 +00:00
* started react motion definitions implementation * added tests * test from repo * updated definitions * chenaged to tsx * Update react-motion-tests.tsx * Update react-motion-tests.tsx
18 lines
419 B
TypeScript
18 lines
419 B
TypeScript
|
|
/// <reference path="../react/react.d.ts" />
|
|
/// <reference path="./react-motion.d.ts"/>
|
|
|
|
import * as React from 'react';
|
|
import {Motion, spring} from 'react-motion';
|
|
|
|
|
|
class Root extends React.Component<{}, {}> {
|
|
render() {
|
|
return (
|
|
<Motion defaultStyle={{ x: 0 }} style = {{ x: spring(10) }}>
|
|
{(value: any) => <div>{ value.x } </div>}
|
|
</Motion>
|
|
);
|
|
}
|
|
}
|