colorfy-software / react-native-modalfy

🥞 Modal citizen of React Native.
https://colorfy-software.gitbook.io/react-native-modalfy
MIT License
1.08k stars 44 forks source link

Fix typechecking of wrapped components #29

Closed wdimmit closed 3 years ago

wdimmit commented 3 years ago

Currently, components wrapped with withModal cannot be type checked properly because the declaration for the WithModalComponent class incorrectly omits all Props. Additionally the incoming component class is mistyped as already containing the modal props.

With these two minor fixes, wrapped components can be successfully type checked and the @ts-ignore overrides can be removed

CharlesMangwa commented 3 years ago

Thanks for the fix @wdimmit! ✨