When the screen loads, I use the following code to focus on a :
useEffect(() => {
InteractionManager.runAfterInteractions(() => {
if (refText.current) {
refText.current.focus();
}
});
}, []);
This works as expected. However, on a submit event, the needs focus again.
function myEvent() {
if (refText.current) {
refText.current.focus();
}
}
This does not focus on the text again. Any ideas?