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 🙏

© 2024 – Pkg Stats / Ryan Hefner

next-supabase-starter

v0.0.2

Published

A scaffolder for Next.js projects with Supabase and shadcn/ui

Downloads

132

Readme

Next.js Supabase shadcn/ui Scaffolder

This package provides a command-line tool to scaffold a Next.js project with Supabase integration and shadcn/ui components. It streamlines the process of setting up a new project with these technologies, allowing you to get started quickly with a powerful tech stack.

Features

  • Scaffolds a Next.js project
  • Integrates Supabase for backend services
  • Optionally includes shadcn/ui components
  • Supports TypeScript
  • Offers choice between Pages Router and App Router
  • Optional TailwindCSS integration
  • Automatic setup of Supabase client
  • Environment variable configuration

Installation

To use this scaffolder, you need to have Node.js and npm installed on your system. Then, you can install the package globally using npm:

npm install -g next-supabase-starter

Usage

After installation, you can create a new project by running:

next-supabase init

This command will start an interactive process to set up your new project.

Configuration Options

During the scaffolding process, you'll be prompted to make several choices:

  1. Project Name: Enter the name for your new project.
  2. TypeScript: Choose whether to use TypeScript (y/n).
  3. App Router: Decide if you want to use Next.js App Router (y/n).
  4. TailwindCSS: Option to include TailwindCSS in your project (y/n).
  5. shadcn/ui: Choose whether to include shadcn/ui components (y/n).
  6. Supabase Project ID: Enter your Supabase project ID.
  7. Supabase API Key: Provide your Supabase API key.

Project Structure

After scaffolding, your project will have the following structure:

your-project-name/
├── .env.local
├── lib/
│   └── supabase.[js|ts]
├── pages/ (or app/ if using App Router)
├── styles/
│   └── globals.css (if using TailwindCSS)
├── components/ (if using shadcn/ui)
├── tailwind.config.js (if using TailwindCSS)
├── package.json
└── README.md

Post-Installation Steps

After the scaffolding process is complete:

  1. Navigate to your project directory:

    cd your-project-name
  2. Start your local Supabase development environment:

    npx supabase start
  3. Start your Next.js development server:

    npm run dev

Additional Information

  • The scaffolder sets up a basic Supabase client in lib/supabase.[js|ts].
  • If you chose to use shadcn/ui, the scaffolder installs the button, card, and tabs components by default.
  • The .env.local file is created with your Supabase URL and API key. Make sure to keep this file secure and do not commit it to version control.

Troubleshooting

If you encounter any issues during the scaffolding process, please check the following:

  1. Ensure you have the latest version of Node.js and npm installed.
  2. Verify that you have the necessary permissions to install global npm packages.
  3. Check that your Supabase project ID and API key are correct.

If problems persist, please open an issue on the GitHub repository.

Contributing

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

License

This project is licensed under the MIT License.