0.1.9 • Published 5 years ago

react-native-contact-input v0.1.9

Weekly downloads
22
License
-
Repository
github
Last release
5 years ago

React-Native-Contact-Input

Single switchable component for email and phone number (web & react-native support) :globe_with_meridians::iphone:

license GitHub top language npm

gif

Installation and usage

Install the package via npm:

npm install --save react-native-contact-input

Then use it in your app:

import React, { Component } from 'react';
import ContactInput from 'react-native-contact-input';

class App extends Component
{

    handleChange=(value)=>{
        console.log(value)
    }
    // => {dialCode: "+91"
           parsedNumber: "+913528712361"
           phoneNumber: "3528712361"
           isValid:true
           }
    
  render()
  {
    return (
        <ContactInput
            onChange={(value,state)=>this.handleChange(value)}
            disableEmail={true}
            style={{
              width:200,
              backgroundColor: 'white',
              alignItems: 'center',
              justifyContent: 'center',}}
        />
    );
  }
}

Props

##Contributing: All your suggestions and PRs are welcome.