Easy Labs
SDKsReact Native

Elements

Native form elements for collecting card data securely on iOS and Android.

Elements are PCI-scoped native input components. Card data is captured inside the element and never enters your app's JavaScript or native heap — only a Basis Theory token reference does. The same engine powers @easylabs/react and @easylabs/browser; on React Native it renders as truly native inputs (not a WebView).

Available elements

ComponentCaptures
CardNumberElementPAN with brand auto-detection
CardExpirationDateElementMM / YY
CardVerificationCodeElementCVC, length-aware per brand
TextElementGeneric sensitive text input

Setup

EasyProvider already wraps BasisTheoryProvider from @basis-theory/react-native-elements, so elements work anywhere inside your provider tree.

Refs and tokenization

Hold a BTRef per element and pass them to the tokenization call when the form submits. Card data never leaves the element.

Styling

Elements accept React Native style props directly — no CSS class indirection. Match your app's design system the same way you'd style a <TextInput>.

Validation

On this page