Socket
Socket
Sign inDemoInstall

rn-local-authentication

Package Overview
Dependencies
0
Maintainers
1
Versions
15
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    rn-local-authentication

The library helps you to authenticate users biometrically


Version published
Weekly downloads
682
increased by6.4%
Maintainers
1
Created
Weekly downloads
 

Readme

Source

React Native Local Authentication

The library helps you to authenticate users biometrically natively on both iOS and Android devices.

Inspired by react-native-fingerprint-scanner and Android BiometricPrompt class that manages a system-provided biometric prompt.

Under construction

Platforms Supported

  • iOS
  • Android

Getting Started

Read Getting Started Guide. If any step seems unclear, please create a detailed issue.

TOC

Versioning

Breaking History:

  • 0.0.1 - iOS authorization
  • 0.0.4 - Android authorization

Upcoming:

  • documentation

    • android installation details
    • ios examples
    • android examples
  • may be check faceID permissions

Usage

iOS example

Import LocalAuthentication from rn-local-authentication and use it like so:


import React from 'react';
import { View } from 'react-native';
import LocalAuthentication from 'rn-local-authentication';

// ...
class MyComponent extends React.Component {
  componentDidMount() {
    LocalAuthentication.authenticateAsync({
      reason: "Authorize please!"
    }).then(response => {
      if (response.success) {
        console.log('Authorized successfully!');
      } else {
        console.log(`Something went wrong. Error: ${response.error}`);
      }
    })
  }

  render() {
    return (<View />);
  }

  // ...
}

link to example launch

License

MIT

Keywords

FAQs

Last updated on 05 Dec 2019

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc