npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

whatsapp-auth

v0.1.2

Published

Module for authenticating applications via WhatsApp

Readme

React Native WhatsApp Login Button

A WhatsApp signIn or signUp button for React Native and Expo.

Motivation

I needed a WhatsApp login button for a project, and all the templates I found were for SMS registration or Social Login.

Even with the popularity of WhatsApp, at most it was used to receive a code for the user to exit the app, copy the code in WhatsApp, return to the app, and paste it.

None worked like the social login mode (like OAuth).

So I decided to create a simple and easy-to-use one.

How it works

Whatsapp Login Button

  • When the button is pressed, it opens the WhatsApp app with the number and message configured in the .env file.

  • Then you can configure your automation service to respond automatically to the user. Setting the DEFAULT_MESSAGE_LOGIN in the .env file.

  • A automation service should respond with a link, to the deeplink lead to the app and in the callbackScreen method login/register the user.

Installation

npm install whatsapp-auth
# or
yarn add whatsapp-auth

Environment Variables

  • WHATSAPP_NUMBER_CORE: The WhatsApp number to be used in the button.
  • DEFAULT_MESSAGE_LOGIN: The default message to be used in the button.

Props

  • whatsappNumberCore: If not provided, the number will be taken from the .env file. The WhatsApp number to be used in the button.
  • defaultMessageLogin: If not provided, the message will be taken from the .env file. The default message to be used in the button.
  • buttonText: The text to be used in the button.

Methods

  • callbackScreen: A function to be called when the button is pressed.

Example

import { WhatsappButton } from 'whatsapp-auth';
import {useNavigation} from '@react-navigation/native';


const App = () => {
  const navigation = useNavigation();

  const callBackScreen = () => {
    console.log('Callback screen');
    navigation.navigate('CodeVerification');
  };

  return <WhatsappButton 
            callBackScreen={callBackScreen}
            whatsappNumberCore={'5511999999999'} // International format (only numbers)
            defaultMessageLogin={'Hello, I want to sign up'}
            buttonText={'Sign Up with WhatsApp'}
          />;
};