Skip to main content

Text

Text is an extension of the React Native Text component, focused on accessibility.

import { Text } from 'react-native-ama';

<Text autofocus>I'm pressable</Text>;

Accessibility improvements

Compared to the default React Native component, this one performs the following checks at runtime:

Minimum size

The component uses the onLayout prop to perform the minium size check.

Additional Props

autofocus

Allows the screen reader to autofocus the Text element when it is rendered.

TypeDefault
booleanundefined
note

When autofocus is set to true, AMA forces the accessibilityRole to header