Version 2.9.13 completely broke react-flip-move for me as a TypeScript user. I'm not fully versed in how the different module/bundling systems work, but it seems that the included bindings exported the type definitions in a way that wasn't aligned with how the component is actually exported. The included test TypeScript file compiled ok, but once you tried to use the component in a TypeScript application, everything blew up at runtime.
Using the export = method in the type definitions fixes these problems. This PR is based on the @types/react-flip-move package's typings with a few additional fixes (the addition of the style and verticalAlignment props) and a combination of tests from both definitions.
The tests can be run (compiled) by running the following command inside typings/:
$ tsc --jsx react ./test.tsx
Note: I'm personally not very experienced with publishing type definitions, so there may be some errors here. However, the @types/react-flip-move definitions have worked well for me so far, and everything seemed to work when I replaced the published NPM package's react-flip-move.d.ts file with the one included in this PR.
Version 2.9.13 completely broke react-flip-move for me as a TypeScript user. I'm not fully versed in how the different module/bundling systems work, but it seems that the included bindings exported the type definitions in a way that wasn't aligned with how the component is actually exported. The included test TypeScript file compiled ok, but once you tried to use the component in a TypeScript application, everything blew up at runtime.
Using the export = method in the type definitions fixes these problems. This PR is based on the @types/react-flip-move package's typings with a few additional fixes (the addition of the
style
andverticalAlignment
props) and a combination of tests from both definitions.The tests can be run (compiled) by running the following command inside
typings/
:Note: I'm personally not very experienced with publishing type definitions, so there may be some errors here. However, the @types/react-flip-move definitions have worked well for me so far, and everything seemed to work when I replaced the published NPM package's
react-flip-move.d.ts
file with the one included in this PR.