# @duffel/react-native-components

A suite of UI components to enable you to sell and manage travel with the Duffel API in your React Native app.

## What's Included

This package provides the following components:

- **Ancillaries** - Allow customers to add bags, seats, and other extras to their bookings
- **Assistant** - Travel assistant to help users work through booking management and connect with customer support
- **Card Form** - Secure card input form
- **3D Secure Provider** - Handle 3DS authentication flows

## Installation

```sh
npm install @duffel/react-native-components
```

### Peer Dependencies

This package requires the following peer dependencies to be installed in your project:

```sh
npm install @duffel/api @evervault/react-native @react-native-picker/picker react-native-mask-input react-native-picker-select react-native-svg react-native-webview
```

### iOS Setup

For iOS, install the native dependencies:

```sh
npx pod-install
```

## Standalone Packages

If you only need specific functionality, consider using our standalone packages for a smaller bundle size and reduced dependencies:

- [`@duffel/react-native-components-ancillaries`](https://www.npmjs.com/package/@duffel/react-native-components-ancillaries)
- [`@duffel/react-native-components-assistant`](https://www.npmjs.com/package/@duffel/react-native-components-assistant)

## Guides

- [Assistant](https://duffel.com/docs/guides/integrating-the-duffel-assistant)
- [Ancillaries](https://duffel.com/docs/guides/ancillaries-component)
- [Ancillaries component customisation](https://duffel.com/docs/guides/ancillaries-component-customisation-in-react-native)
- [3DS hook](https://duffel.com/docs/guides/using-3ds-hook-in-react-native)
- [Card form](https://duffel.com/docs/guides/card-form-component-with-3dsecure)
