TypeScript type definitions and TypeScript support
naftalimurgor opened this issue · 2 comments
Hi,
I'm working on migrating a portion of the Mattermost-webapp to TypeScript, in this issue: mattermost/mattermost#17289 I ran into a challenge where the component dynamic-virtualized-list lacks Type definitions as it is written in Flow and JavaScript.
Options to accomplish TypeScript support would be:
- To migrate the component to TypeScript or
- Write type definitions and publish to Definitely type so that they are availabe on npm and installable like:
npm install -D @types/dynamic-virtualized-list
So I went ahead and wrote some Type definitions for this component here https://github.com/naftalimurgor/dynamicSizeList-ts.git
am left with deploying to Definitely Typed.
Please let me know how best to approach this. I also need some help deploying to Definitely Typed if deemed possible. Thanks
Hey @naftalimurgor, really nice work on this!
I'd definitely be on board with using the type definitions you've created here, though I understand it will take some time to deploy to DefinitelyTyped, as much as that would be the ideal case.
I think what might be best for now is to add these types directly to the mattermost-webapp
repository under types/external
and leave a comment to migrate over to DefinitelyTyped once they're merged.
Let me know if this makes sense to you.
hey @devinbinnie
Adding the types to mattermost-webapp
under types/external
path makes perfect sense to use in the meantime.
I appreciate your feedback.
Thank you.