Skip to content

Sohibaki/appwrite-nextjs-starter

Β 
Β 

Repository files navigation

πŸš€ Appwrite NextJS Starter

A starter template for building web applications with Next.js and Appwrite.

πŸ“š Overview

This starter template provides everything you need to build a modern web application with Next.js and Appwrite. It includes a full authentication system, user profile management, and a clean, responsive UI.

Perfect for quickly bootstrapping your next project without spending time on repetitive setup tasks.

✨ Features

  • πŸ” Authentication Flows
    • πŸ“§ Email & Password Sign In/Sign Up
    • πŸ”„ Password Recovery Process
    • πŸ”‘ OAuth Integration (GitHub, Google, etc.)
  • πŸ“Š Data Management
    • ✏️ Complete CRUD Operations Examples
    • πŸ“ File Storage Implementations
    • ⚑ Realtime Updates
    • πŸ”„ Cache Invalidation
  • πŸ‘₯ Team Management
    • 🏒 Create and Manage Teams
    • πŸ‘₯ Invite Team Members
    • πŸ‘‘ Role-based Permissions (Owner, Admin, Member)
    • πŸšͺ Join/Leave Teams
    • πŸ”’ Team-specific Content Access
  • πŸ‘€ User Management
    • πŸ‘¨β€πŸ’» Profile Editing & Customization
    • πŸ”— Team Affiliations
  • πŸ“‹ General
    • πŸ›‘οΈ Protected Routes
    • 🎨 TailwindCSS
    • πŸ“± Responsive Design

πŸ“‹ Prerequisites

βš™οΈ Installation

  1. Clone this repository:
git clone https://github.com/diswasher-detergent/appwrite-nextjs-starter.git
  1. Navigate to the project:
cd appwrite-nextjs-starter
  1. Install dependencies:
pnpm install
  1. Create a .env file based on the .env.sample file:

    • Create an API key in Appwrite, with the permissions session.write and upadte the .env with that key.
  2. Start the development server:

pnpm run dev
  1. Open http://localhost:3000 in your browser to see the application.

🚒 Deploying Project using the Appwrite CLI

Appwrite CLI allows you to automate and streamline your Appwrite workflows.

πŸ“₯ Installation

Install the Appwrite CLI globally:

npm install -g appwrite-cli

πŸ”§ Setup

  1. Login to your Appwrite account:
appwrite login

πŸš€ Push to Appwrite

  1. Deploy the project:
appwrite push settings
  1. Deploy the database:
appwrite push collections
  1. Deploy the bucket:
appwrite push buckets

πŸ”‘ Adding GitHub OAuth to Appwrite

  1. πŸ”— Go to your GitHub Developer Settings and create a new App.

  2. πŸ”„ Set the Authorization callback URL to:

https://cloud.appwrite.io/v1/account/sessions/oauth2/callback/github/appwrite-nextjs-starter
  1. πŸ” After creating the OAuth App, you'll receive a Client ID and need to generate a Client Secret.

  2. βš™οΈ In your Appwrite Console, navigate to Auth β†’ Settings β†’ OAuth2 Providers.

  3. βœ… Enable the GitHub provider and enter the Client ID and Client Secret from GitHub.

  4. πŸ’Ύ Save your changes.

πŸ‘₯ Contributing

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

πŸ“„ License

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

About

πŸš€ Appwrite NextJS Starter: A starter template for building web applications with Next.js and Appwrite.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • TypeScript 98.6%
  • CSS 1.2%
  • JavaScript 0.2%