🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
Book a DemoInstallSign in
Socket

@inertiapixel/react-auth

Package Overview
Dependencies
Maintainers
1
Versions
26
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@inertiapixel/react-auth

InertiaPixel: Authentication library for React and Next.js projects, supporting credential, social login, JWT handling, and context-based state.

1.1.18
latest
Source
npm
Version published
Weekly downloads
58
87.1%
Maintainers
1
Weekly downloads
 
Created
Source

InertiaPixel React/NextJs Auth Library

InertiaPixel Auth

react-auth

Authentication library for React and Next.js. Supports credential and social login, JWT token handling, and context-based auth state — built for scalable, multi-project use.

🚀 Installation

Install the package via npm:

npm install @inertiapixel/react-auth

🚀 Features

  • ✅ Easy setup with AuthProvider
  • 🔒 JWT-based authentication
  • 🔑 Supports:
    • Credentials login (email + password)
  • 🧠 Context-driven auth state
  • 📦 Built-in utilities like useAuth, Protect, SignedIn, SignedOut
  • 🧪 Type-safe API (written in TypeScript)
  • ⚙️ Plug-and-play for scalable projects

🛠️ Basic Usage

1. Wrap your App with AuthProvider

// pages/_app.tsx
import { AuthProvider, SignedIn, SignedOut } from '@inertiapixel/react-auth'
import type { AppProps } from 'next/app'

export default function MyApp({ Component, pageProps }: AppProps) {
  return (
    <AuthProvider config={{ tokenKey: 'token', redirectTo: '/' }}>
      <SignedIn>
        <Component {...pageProps} />
      </SignedIn>
      <SignedOut>
        <p>Please sign in</p>
      </SignedOut>
    </AuthProvider>
  )
}

Authors

  • Md Asif - LinkedIn

Website

🔗 www.inertiapixel.com/

License

This icon set is free and open-source under the MIT License.
See the full license here.

Crafted in India by InertiaPixel

Keywords

react

FAQs

Package last updated on 10 May 2025

Did you know?

Socket

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