1.0.1 • Published 8 months ago

react-native-book-a-flight v1.0.1

Weekly downloads
-
License
MIT
Repository
github
Last release
8 months ago

React Native Book A Flight

A React Native component for integrating flight booking functionality into your mobile app.

Installation

npm install @alvinapp/react-native-book-a-flight
# or
yarn add @alvinapp/react-native-book-a-flight

Usage

import { BookFlight } from '@alvinapp/react-native-book-a-flight';

export default function App() {
  const handleBookingComplete = (bookingDetails) => {
    console.log('Booking completed:', bookingDetails);
  };

  return (
    <BookFlight
      publicKey="your_public_key_here"
      onBookingComplete={handleBookingComplete}
    />
  );
}

Props

  • publicKey (string): Your API public key
  • identifier (string, optional): Custom identifier
  • token (string, optional): Authentication token
  • styleUrl (string, optional): URL for custom styles
  • settings (string, optional): Custom settings
  • uuid (string, optional): Unique identifier
  • userObject (object, optional): User information
    • first_name (string, optional)
    • last_name (string, optional)
    • email (string, optional)
  • onBookingComplete (function, optional): Callback when booking is completed
  • style (object, optional): Custom styles for the container

License

MIT

1.0.1

8 months ago

1.0.0

8 months ago