GiftedChatProps does not use GiftedChat TMessage generic type parameter
Issue Description
GiftedChatProps does not use GiftedChat TMessage generic type parameter. Without this, types that extend IMessage will have type mismatch errors when used as props; e.g. Type 'MyMessage | undefined' is not assignable to type 'Message | undefined'.
Steps to Reproduce / Code Snippets
This line: https://github.com/FaridSafi/react-native-gifted-chat/blob/ba06287912151dbfb71951893d0454db8aafd5a5/src/GiftedChat.tsx#L55C38-L55C38
This seems to be a bug since GiftedChatProps has its own TMessage type parameter which is passed to other prop types.
Expected Results
GiftedChatProps should use TMessage as a type param:
declare function GiftedChat<TMessage extends IMessage = IMessage>(props: GiftedChatProps<TMessage>): JSX.Element;
Additional Information
- react-native-gifted-chat version: 2.4.0
I added a PR to fix the problem with types: https://github.com/FaridSafi/react-native-gifted-chat/pull/2576
I think this is no longer relevant. Fixed in my PR already, merged: https://github.com/FaridSafi/react-native-gifted-chat/pull/2576
Should be fixed in master