react-native-easy-toast
react-native-easy-toast copied to clipboard
prop 'style' not defined
Getting the property 'style' not defined error while using in TypeScript:
(JSX attribute) style: { backgroundColor: string; } No overload matches this call. Overload 1 of 2, '(props: ToastComponentProps | Readonly<ToastComponentProps>): Toast', gave the following error. Type '{ ref: (toast: Toast | null) => void; style: { backgroundColor: string; }; position: "bottom"; positionValue: number; fadeInDuration: number; fadeOutDuration: number; opacity: number; textStyle: { ...; }; }' is not assignable to type 'IntrinsicAttributes & IntrinsicClassAttributes<Toast> & Readonly<ToastComponentProps> & Readonly<...>'. Property 'style' does not exist on type 'IntrinsicAttributes & IntrinsicClassAttributes<Toast> & Readonly<ToastComponentProps> & Readonly<...>'. Overload 2 of 2, '(props: ToastComponentProps, context: any): Toast', gave the following error. Type '{ ref: (toast: Toast | null) => void; style: { backgroundColor: string; }; position: "bottom"; positionValue: number; fadeInDuration: number; fadeOutDuration: number; opacity: number; textStyle: { ...; }; }' is not assignable to type 'IntrinsicAttributes & IntrinsicClassAttributes<Toast> & Readonly<ToastComponentProps> & Readonly<...>'. Property 'style' does not exist on type 'IntrinsicAttributes & IntrinsicClassAttributes<Toast> & Readonly<ToastComponentProps> & Readonly<...>'.ts(2769)
Found one pull request #97 with the fix for the same, but seems like not merged yet.
I'm facing this same issue as well. Any idea when this
Getting the property 'style' not defined error while using in TypeScript:
(JSX attribute) style: { backgroundColor: string; } No overload matches this call. Overload 1 of 2, '(props: ToastComponentProps | Readonly<ToastComponentProps>): Toast', gave the following error. Type '{ ref: (toast: Toast | null) => void; style: { backgroundColor: string; }; position: "bottom"; positionValue: number; fadeInDuration: number; fadeOutDuration: number; opacity: number; textStyle: { ...; }; }' is not assignable to type 'IntrinsicAttributes & IntrinsicClassAttributes<Toast> & Readonly<ToastComponentProps> & Readonly<...>'. Property 'style' does not exist on type 'IntrinsicAttributes & IntrinsicClassAttributes<Toast> & Readonly<ToastComponentProps> & Readonly<...>'. Overload 2 of 2, '(props: ToastComponentProps, context: any): Toast', gave the following error. Type '{ ref: (toast: Toast | null) => void; style: { backgroundColor: string; }; position: "bottom"; positionValue: number; fadeInDuration: number; fadeOutDuration: number; opacity: number; textStyle: { ...; }; }' is not assignable to type 'IntrinsicAttributes & IntrinsicClassAttributes<Toast> & Readonly<ToastComponentProps> & Readonly<...>'. Property 'style' does not exist on type 'IntrinsicAttributes & IntrinsicClassAttributes<Toast> & Readonly<ToastComponentProps> & Readonly<...>'.ts(2769)
Found one pull request #97 with the fix for the same, but seems like not merged yet.
Facing same issue. Any idea when will this get merged?
same here
Facing same issue too. pls...😭
same