DEV Community

Cover image for Vue Supabase Auth Template with Protected Routes
mmvergara
mmvergara

Posted on β€’ Edited on

1 1 1 1 1

Vue Supabase Auth Template with Protected Routes

Pretty much a barebones minimal template to get you started with authentication and protected routes.

🌐 App Demo

Features

  • πŸš€ Protected Routes
  • πŸš€ Supabase Session Object in Global via useAuthStore
  • πŸš€ User Authentication
  • πŸš€ Routing and Route Guards
  • πŸš€ Minimal

It's also blazingly fast πŸ”₯ No really, try it out for yourself.

Getting Started

  1. Clone the repository
  2. Install dependencies: npm install
  3. Create .env using the .env.example as a template
VITE_SUPABASE_URL=
VITE_SUPABASE_ANON_KEY=
Enter fullscreen mode Exit fullscreen mode
  1. Run the app: npm run dev

Files you need to see so you can understand how it works.

  • src/stores/auth.ts
  • src/router/index.ts
  • All Pages

GitHub logo mmvergara / vue-supabase-auth-starter-template

Vue Supabase Auth Starter Template with Protected Routes

Vue Supabase Auth with Protected Routes

🌐 App Demo

Features

  • πŸš€ Protected Routes
  • πŸš€ Supabase Session Object in Global via useAuthStore
  • πŸš€ User Authentication
  • πŸš€ Routing and Route Guards
  • πŸš€ Minimal

It's also blazingly fast πŸ”₯ No really, try it out for yourself.

Getting Started

  1. Clone the repository
  2. Install dependencies: npm install
  3. Create .env using the .env.example as a template
VITE_SUPABASE_URL=
VITE_SUPABASE_ANON_KEY=
  1. Run the app: npm run dev

Files you need to see so you can understand how it works.

  • src/stores/auth.ts
  • src/router/index.ts
  • All Pages





We also have a similar template for FIREBASE πŸ”₯

Top comments (0)

A Workflow Copilot. Tailored to You.

Pieces.app image

Our desktop app, with its intelligent copilot, streamlines coding by generating snippets, extracting code from screenshots, and accelerating problem-solving.

Read the docs