Remove Listener?
Dror-Bar opened this issue · 0 comments
Dror-Bar commented
In the example - once activated, the SmsListener is only removed after an Sms is received.
What if an Sms isn't received? what if the app is closed?
This could lead to potential data leak.
You should remove the listener when the component unmounts - for example, using useEffect.
The example should be updated to represent this. I think it's really important.