4 ms·
> failed to set the appropriate accessibility roles so the button actually appears as button to a user with the screen reader Appreciate that you looked into i
by scarlac 7y ago
> failed to set the appropriate accessibility roles so the button actually appears as button to a user with the screen reader
Appreciate that you looked into it. On iOS and you do not need to set anything to become screen reader friendly _in React Native_. The default TouchableOpacity with a simple piece of text inside of it will become focusable and iOS will read the text aloud for you. This works because RN uses native elements unlike Flutter, Electron, and others.
In fact, I took you up on the claim that it wouldn't read correctly. I used my app just now which has never been tested or optimized for accessibility. Covered my eyes and began navigating. It works just fine! All tappable elements are indeed read aloud. I was able to navigate through the app settings, change them, go back, and reload other screens, navigate to the updated content, and perform actions on the new content.
Please do not put RN in the same bucket as Flutter or Electron. They are fundamentally differently.