Cursor Prompt Library for SaaSKit - vm5lab/SaaSKit GitHub Wiki

๐ŸŽฏ Cursor Prompt Library for SaaSKit

This guide is a curated list of AI prompts optimized for Cursor, designed to accelerate the development of SaaSKit โ€” a modern SaaS framework built with Next.js 15, Supabase, Prisma, and Tailwind.


๐Ÿงฑ Project Initialization

๐Ÿ”น Scaffold Project

Create a modern SaaS boilerplate using Next.js 15 App Router, React 19, Supabase, Prisma, Tailwind CSS, MUI, and TypeScript.

๐Ÿ”น Generate Folder Structure

Generate a folder structure for a SaaS dashboard project including app, components, lib, prisma, and layout directories.

๐Ÿ”น Set up .env File

Add required environment variables for Supabase and describe their purpose.

๐Ÿ–ฅ๏ธ UI & Layout

๐Ÿ”น Sidebar + Topbar Layout

Create a responsive layout with a collapsible Sidebar and a Topbar using Tailwind and MUI.

๐Ÿ”น Dark Mode Support

Add dark mode toggle to the layout using Tailwind's dark: variant and MUI theming.

๐Ÿ”น Reusable UI Components

Generate a Button component with variants for primary, secondary, and outline using Tailwind and MUI.

๐Ÿ” Authentication & RBAC

๐Ÿ”น Supabase Login Page

Create a login page that authenticates users using Supabase Email Magic Link login.

๐Ÿ”น RBAC Middleware

Write middleware that redirects non-admin users from accessing /admin routes based on user role.

๐Ÿ”น Supabase RLS Policy

Generate a Row-Level Security policy for Supabase that allows users to access only their own records.

๐Ÿงฌ Prisma & Database

๐Ÿ”น Define Models

Create a Prisma schema with User, Project, and Team models. Link Project to User with a foreign key.

๐Ÿ”น Push Schema

Generate the command and instructions to push the Prisma schema to Supabase.

โš™๏ธ Server Actions

๐Ÿ”น Create Project Action

Create a Server Action that accepts form data, validates input, and inserts a new project into the database.

๐Ÿ”น Add Error Handling

Add try-catch error handling to this Server Action with a user-friendly error message.

๐Ÿ”น Form + Server Action Example

Build a form component that submits data to a Server Action and displays loading and error states.

๐Ÿš€ Deployment & CI/CD

๐Ÿ”น Vercel Deployment Guide

Write deployment steps for deploying a Next.js 15 app to Vercel including environment variables and Supabase setup.

๐Ÿงช Testing & Refactoring

๐Ÿ”น Unit Test Generator

Write unit tests for this function using Jest, including success and error cases.

๐Ÿ”น Refactor for Readability

Refactor this function to improve readability and maintainability.

๐Ÿ”น Performance Optimization

Optimize this React component for rendering performance and memoization.

๐Ÿ“š Documentation & Comments

๐Ÿ”น Generate JSDoc

Add JSDoc comments to this function explaining its parameters, return values, and usage.

๐Ÿ”น README.md Generator

Generate a README.md file for this SaaSKit project with sections for setup, usage, and deployment.

๐Ÿง  Cursor Pro Tips

  • Use // describe: comments to help Cursor understand the file's intent.
  • Prefer small, atomic prompts over large, vague requests.
  • Use โŒ˜+K to access "Explain", "Refactor", and "Generate Tests" on selected code.

This prompt library is designed to help you build, extend, and optimize SaaSKit rapidly with Cursor as your AI pair programmer.