react-native-easy-toast
react-native-easy-toast copied to clipboard
Fix `setState` warning
This PR fixes a warning that can be trigged if and when the component tries to call setState
when no longer mounted. The fix involves maintaining a flag that is updated when the component mounts/unmounts and only calling setState
if the flag indicates that the component is currently mounted.