You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Indeed that might be interesting, might be worth to experiment with.
However, I am a bit skeptical about how beneficial that would be - my feeling is that in most cases where annotations are missing - TypeScript can successfully infer them, and so adding more flow based types might only increase amount of fixes to be made manually…
Other thing in this direction, that might be more interesting to look into - codemod provided by flow team for "type first" type annotations - https://flow.org/en/docs/cli/annotate-exports/
Theoretically it should add type annotation are to be added only at module boundaries(which is generally what is preferred for typescript as well), and so - there should be not much noise from it, but noticeable improvement in type coverage. Yet to try using it…
oh neat, i was about to write something that uses type-at-pos to augment flowts. it would be real handy for cleaning up the implicit anys that pop up during conversion.
Interesting concept. Wondering if this could be something that is also interesting for flowts: https://github.com/Airtable/typescript-migration-codemod/blob/main/src/typescript/flow_type_at_pos.ts
This would add annotations, where flow knows the type so it would increase type coverage. Just bringing that up in case you are interested.
The text was updated successfully, but these errors were encountered: