Skip to main content

Touchable* Drop role and Some aria-* Props

Touchable* build their native view from a fixed list of props, and in React Native 0.88 role is on none of the lists. <TouchableOpacity role="button"> has no role; accessibilityRole="button" works. TouchableWithoutFeedback also drops aria-label, and TouchableHighlight drops aria-checked and the other aria-* state props.

  • Checked: 22–23 October 2026
  • Versions: React Native 0.88.0
  • Devices: iOS 27.0 Simulator (Accessibility Inspector), Android 17 emulator (uiautomator dump)
  • Upstream: react/react-native#59378: open

How It Was Checked​

Pairs in the reproducer, the aria-* or role prop next to its accessibility* form:

<>
<TouchableOpacity role="button" onPress={save}>
<Text>Save G</Text>
</TouchableOpacity>
<TouchableOpacity accessibilityRole="button" onPress={save}>
<Text>Save H</Text>
</TouchableOpacity>
</>

Result​

ComponentPropAndroid 17iOS 27
TouchableOpacityrole="button"android.view.ViewGroupNo Button trait
TouchableWithoutFeedbackaria-label="Close I"content-desc="×" (the child)Label "×"
TouchableHighlightaria-checkedcheckable="false"No "checked" in the value

With the accessibility* form each of them is right: android.widget.Button and the Button trait, the label "Close J", checked="true".

  • TouchableNativeFeedback drops role too (read from the code, not run).
  • aria-labelledby is dropped by all four (read from the code).
  • Pressable does not have these gaps: it passes its props on to a View.

Upstream​