Giter Site home page Giter Site logo

next-supabase-shadcn's Introduction

next-supabase-shadcn

A fullstack template using Next.js, Supabase, Tailwind CSS (shadcn/ui), and TypeScript.

Features

  • ๐Ÿš€ Next.js 14 with /app router and SSR
  • ๐Ÿ” Supabase for auth and database
  • ๐ŸŽจ Tailwind CSS with shadcn/ui
  • ๐Ÿ“˜ TypeScript support throughout, including auto-generated types for Supabase tables
  • โœ‰๏ธ Email signup and login using PKCE flow with @supabase/ssr
  • ๐ŸŒ— Dark/light mode using next-themes
  • ๐Ÿ”’ Protected routes via Next.js middleware
  • ๐Ÿ›ก๏ธ Protected CRUD operations via row level security
  • ๐Ÿž Toast notifications
  • ๐Ÿ“ฑ Responsive layouts
  • ๐Ÿ“„ Example pages with metadata and React context providers

Coming soon (please make a PR if you want to contribute)...

  • ๐Ÿ“š /docs pages
  • ๐Ÿ”‘ OAuth logins
  • ๐Ÿงช Database tests for RLS policies

Setup

Clone the repo, then install all dependencies using yarn:

yarn install

Start a local supabase instance. This will download the latest docker image and start a local instance of supabase.

yarn supabase start

Create a .env.local file with the enviroment variables defined in .env.local.example. The NEXT_PUBLIC_SUPABASE_URL and NEXT_PUBLIC_SUPABASE_ANON_KEY defined in .env.local.example should work for all local supabase instances. If you wish to use a remote supabase instance, the public Supabase URL and API key can be found in your dashboard.

Devlopment

Start the local next.js server:

yarn dev

If you wish to reset your local supabase database, run the command below. This will run any migrations in supabase/migrations and reset the database to the initial state defined in supabase/seed.sql.

yarn supabase db reset

Note that signups will require email confirmation by default. If you are running Supabase locally, you can find an Inbucket server at http://localhost:54324/ that will store all emails sent by your local Supabase instance.

next-supabase-shadcn's People

Contributors

wantpinow avatar

Stargazers

 avatar  avatar

Watchers

 avatar

Forkers

thebadking

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.