Skip to content

Commit c764f96

Browse files
mdneyazahmadnecolas
authored andcommitted
[fix] Allow TextInput to dispatch 'submit' event
Close #2371
1 parent b6c8da8 commit c764f96

File tree

1 file changed

+1
-1
lines changed
  • packages/react-native-web/src/exports/TextInput

1 file changed

+1
-1
lines changed

packages/react-native-web/src/exports/TextInput/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -296,7 +296,7 @@ const TextInput: React.AbstractComponent<
296296
onSubmitEditing(e);
297297
}
298298
if (shouldBlurOnSubmit && hostNode != null) {
299-
hostNode.blur();
299+
setTimeout(() => hostNode.blur(), 0);
300300
}
301301
}
302302
}

0 commit comments

Comments
 (0)