Open alexreardon opened 5 years ago
For me personally this is not a negative reflection on flow
. I really enjoy using it. However, there are advantages for us in consolidating on a type system internally. Also, my understanding is that TypeScript
is a more popular project so a lot more people will get first class types when we move over
❤️
I would prefer you to keep flow types up-to-date in this repo. As you can see there's not so much people who will maintain them separately.
How about rewriting with reason? Type system is much nicer.
@alexreardon This is an exciting development! Since Typescript is more widely used, it will also help make it easier for people to contribute to the project. Within 2019, what is your expected timeline for this migration?
Just as we didn't want to maintain TS types when the source was in Flow, I don't think it's worth maintaining Flow types when moving to TS.
@lilymatcha Alex will be back mid-Jan. See #1010 for more details.
@treshugart Flow types will be maintained. There are existing users.
@TrySound I am still thinking of the best way to maintain the flow types. Given they already exist I am open to having them in the repo. Once we start on the TypeScript conversion then we will have a better idea what the story could be
Types will be quite small. So it won't take a lot of efforts to maintain them. Keeping them separately will make them out of date soon.
@alexreardon good news for typescript. Do you guys also plan to move over Atlaskit?
@alexreardon Great initiatives! For initial step, any thoughts of moving @types/react-beautiful-dnd
to this repos?
@alexreardon Has the migration to TS been abandoned?
Hey guys, thought I would give it a shot
I tried running Khan Academy's flow-to-ts on a single file and it seems to do a decent job. Sure that it's not the only change need to be done, but it seems like a good start for the bulk of the code.
I'm just wondering how we should manage the existing PRs, 99% of the files would be completely different after the transition: The file names would be .ts
/.tsx
instead of .js
/.jsx
, the content would quite different as well and some config file would require changes as well. Only solution I can think of is to write a bash script that does this transition automatically so it could be applied on forked repos as well. The only problem with that is that applying all of the changes using script may be quite complicated...
Would love to hear your thoughts about it
Cheers
UPDATE: started out here
react-beautiful-dnd
has been fully migrated to TypeScript
here: https://github.com/react-forked/dnd :slightly_smiling_face: The repo is a fork of rbd
that I plan to maintain.
Here's a blog post about it. Give it a try :slightly_smiling_face:
At Atlassian we consolidating on a single type system:
TypeScript
.In 2019 we plan on moving
react-beautiful-dnd
toTypeScript
.We still hope to have a good
flow
story through theflowtyped
project. We can essentially just use our existingflow
types for areact-beautiful-dnd
library definition.