rnh

react-native-hide-show-password-input

React-Native Hide Show Password InputText Component

Showing:

Popularity

Downloads/wk

3.2K

GitHub Stars

62

Maintenance

Last Commit

10mos ago

Contributors

8

Package

Dependencies

3

License

MIT

Type Definitions

Tree-Shakeable

No?

Readme

React-Native Hide Show Password InputText Component

npm version

This is a custom component for React Native, a simple Hide Show Password InputText, compatible with both ios and android.

demo

Installation.

Install the package with NPM.

npm install react-native-hide-show-password-input --save

Or with YARN

yarn add react-native-hide-show-password-input

Link vector icons library

react-native link react-native-vector-icons

How to use.

Very simple to use just add this component in your file.

// import packages
import React, { Component } from 'react';
import { View } from 'react-native';
import PasswordInputText from 'react-native-hide-show-password-input';

export default class App extends Component {

  constructor(props) {
    super(props);
    this.state = {
      password: '',
    };
  }
  
  render() {
    const { password } = this.state;
    
    return (
      <View style={{ margin: 20 }}>

        <PasswordInputText
          getRef={input => this.input = input}
          value={password}
          onChangeText={(password) => this.setState({ password })}
        />

        <Button
          title="Clear"
          onPress={() => this.input.clear()} />
          
      </View>
    );
  }
}

Properties

namedescriptiontypedefault
iconSizeEye icon sizeNumber25
iconColorEye icon colorString#222222
labelText Input animate labelStringPassword
getRefReference callbackFunction-

Note: You can use properties of react-native-material-textfield and TextInput.

Rate & Review

Great Documentation0
Easy to Use0
Performant0
Highly Customizable0
Bleeding Edge0
Responsive Maintainers0
Poor Documentation0
Hard to Use0
Slow0
Buggy0
Abandoned0
Unwelcoming Community0
100
No reviews found
Be the first to rate

Tutorials

No tutorials found
Add a tutorial