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

nextjs-redux-api-core

v1.0.0

Published

πŸš€ Next.js 16 Enterprise Starter Kit with Redux Toolkit, RTK Query, NextAuth v5, and Clean Architecture. Production-ready boilerplate for building scalable web applications.

Readme


✨ Features

| Feature | Description | |---------|-------------| | ⚑ Next.js 16 | Latest App Router with Turbopack for lightning-fast development | | πŸ” NextAuth v5 | Secure authentication with JWT & session support | | πŸ—ƒοΈ Redux Toolkit | Efficient state management with RTK Query for API calls | | 🎨 Tailwind CSS v4 | Modern utility-first CSS with tw-animate-css | | πŸ“± Responsive | Mobile-first design with shadcn/ui components | | πŸ—οΈ Clean Architecture | Feature-sliced design for scalable codebase | | πŸ”„ Token Monitor | Built-in token refresh and session management | | πŸ“Š Progress Bar | NProgress integration for page transitions | | πŸŒ™ Dark Mode | Built-in theme switching with next-themes | | πŸ›‘οΈ TypeScript | Full type safety throughout the codebase |

πŸš€ Quick Start

Create a New Project

# Using npx (recommended)
npx nextjs-redux-api-core my-app

# Or using npm
npm exec nextjs-redux-api-core my-app

# Or install globally
npm install -g nextjs-redux-api-core
create-nxcore my-app

Start Development

cd my-app
npm run dev

Open http://localhost:4000 to see your app.

πŸ“ Project Structure

my-app/
β”œβ”€β”€ πŸ“‚ app/                    # Next.js App Router
β”‚   β”œβ”€β”€ (auth)/               # Auth routes (sign-in, sign-up)
β”‚   β”œβ”€β”€ (root)/               # Protected routes
β”‚   β”œβ”€β”€ api/                  # API routes
β”‚   β”œβ”€β”€ layout.tsx            # Root layout
β”‚   └── globals.css           # Global styles
β”‚
β”œβ”€β”€ πŸ“‚ components/             # Shared UI components
β”‚   β”œβ”€β”€ layout/               # Layout components
β”‚   β”œβ”€β”€ molecules/            # Composite components
β”‚   └── ui/                   # Base UI components (shadcn)
β”‚
β”œβ”€β”€ πŸ“‚ config/                 # App configuration
β”‚   β”œβ”€β”€ constants.ts          # App constants
β”‚   β”œβ”€β”€ env.ts               # Environment config
β”‚   β”œβ”€β”€ routes.ts            # Route definitions
β”‚   └── modules.ts           # Module registry
β”‚
β”œβ”€β”€ πŸ“‚ infrastructure/         # Technical layer
β”‚   β”œβ”€β”€ api/                  # RTK Query base config
β”‚   β”œβ”€β”€ auth/                 # NextAuth configuration
β”‚   β”œβ”€β”€ hooks/                # Global hooks
β”‚   β”œβ”€β”€ providers/            # App providers
β”‚   └── store/                # Redux store setup
β”‚
β”œβ”€β”€ πŸ“‚ modules/                # Feature modules
β”‚   β”œβ”€β”€ auth/                 # Authentication module
β”‚   β”‚   β”œβ”€β”€ api/             # Auth API endpoints
β”‚   β”‚   β”œβ”€β”€ components/      # Auth UI components
β”‚   β”‚   β”œβ”€β”€ hooks/           # Auth hooks
β”‚   β”‚   β”œβ”€β”€ services/        # Auth business logic
β”‚   β”‚   β”œβ”€β”€ store/           # Auth state slice
β”‚   β”‚   └── types/           # Auth types
β”‚   └── menu/                 # Menu module
β”‚
β”œβ”€β”€ πŸ“‚ lib/                    # Utility functions
β”‚   β”œβ”€β”€ utils.ts             # General utilities
β”‚   β”œβ”€β”€ formatters.ts        # Data formatters
β”‚   └── validators.ts        # Validation helpers
β”‚
β”œβ”€β”€ πŸ“‚ types/                  # Global type definitions
β”‚   β”œβ”€β”€ global.d.ts          # Global types
β”‚   └── next-auth.d.ts       # NextAuth type extensions
β”‚
└── πŸ“‚ assets/                 # Static assets
    └── styles/              # Global stylesheets

πŸ—οΈ Architecture Overview

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                         APP LAYER                                β”‚
β”‚  Next.js App Router - Routes, Layouts, Pages                    β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                              β”‚
                              β–Ό
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                      FEATURE MODULES                             β”‚
β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”               β”‚
β”‚  β”‚    Auth     β”‚ β”‚    Menu     β”‚ β”‚   [Your]    β”‚               β”‚
β”‚  β”‚   Module    β”‚ β”‚   Module    β”‚ β”‚   Module    β”‚               β”‚
β”‚  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜               β”‚
β”‚  Components β€’ Hooks β€’ Services β€’ Store β€’ Types                  β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                              β”‚
                              β–Ό
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                    INFRASTRUCTURE LAYER                          β”‚
β”‚  Redux Store β€’ NextAuth β€’ RTK Query β€’ Providers                 β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                              β”‚
                              β–Ό
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                    SHARED COMPONENTS                             β”‚
β”‚  UI Components β€’ Layout β€’ Molecules                             β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

πŸ“ Environment Variables

Create a .env.local file in the root directory:

# App Configuration
NEXT_PUBLIC_APP_NAME="Your App Name"
NEXT_PUBLIC_APP_URL="http://localhost:4000"
NEXT_PUBLIC_API_URL="http://localhost:4000/api"

# Authentication (Required)
AUTH_SECRET="your-secret-key"  # Generate: openssl rand -base64 32
AUTH_URL="http://localhost:4000"

# Database (Optional)
DATABASE_URL="postgresql://user:password@localhost:5432/mydb"

πŸ› οΈ Available Scripts

| Command | Description | |---------|-------------| | npm run dev | Start development server on port 4000 | | npm run build | Build for production | | npm run start | Start production server | | npm run lint | Run ESLint |

πŸ“š Feature Module Template

Create new features following this structure:

modules/
  [feature-name]/
    β”œβ”€β”€ components/           # UI components
    β”‚   β”œβ”€β”€ [Feature]Page.tsx
    β”‚   └── index.ts
    β”œβ”€β”€ hooks/               # React hooks
    β”‚   └── use[Feature].ts
    β”œβ”€β”€ services/            # Business logic
    β”‚   └── [feature].service.ts
    β”œβ”€β”€ store/               # Redux slice (optional)
    β”‚   └── [feature]Slice.ts
    β”œβ”€β”€ api/                 # RTK Query endpoints
    β”‚   └── [feature]Api.ts
    β”œβ”€β”€ types/               # TypeScript types
    β”‚   └── index.ts
    └── index.ts             # Public exports

🀝 Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

πŸ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.

πŸ™ Acknowledgments