Difference between RN's and DT's SyntheticEvent type #17
Labels
help wanted
Extra attention is needed
type difference
All about differences between Flow and TS typings (e.g. in React)
In RN’s upstream type, most of the properties are
Maybe
types. Whereas in DT’s React type they are all required properties. This means that a value with RN’s type cannot be assigned to a target that expects DT’s type.I only came across 1 such case in Artsy’s codebase, which I solved locally with a utility type that removes all the
Maybe
variants. It is unclear if this issue structurally applies to RN projects or is more of an issue with e.g. Formik relying on HTML event types.The text was updated successfully, but these errors were encountered: