The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.
TypeScript aialternativeauthdatabasedenoembeddingsexamplefirebasenextjsoauth2pgvectorpostgispostgrespostgresqlpostgrestrealtimesupabasevectorswebsockets
docs: Update the prompt examples to make it more Cursor friendly (#33315)
Tyler806a8227b9d2
diff --git a/apps/docs/content/guides/getting-started/ai-prompts.mdx b/apps/docs/content/guides/getting-started/ai-prompts.mdxindex 412364c2bfb..706a56033ba 100644--- a/apps/docs/content/guides/getting-started/ai-prompts.mdx+++ b/apps/docs/content/guides/getting-started/ai-prompts.mdx@@ -3,13 +3,13 @@ title: AI Promptssubtitle: Prompts for working with Supabase using AI-powered IDE tools----We've curated a selection of prompts to help you work with Supabase using your favorite AI-powered IDE tools, such as GitHub Copilot or Cursor.+We've curated a selection of prompts to help you work with Supabase using your favorite AI-powered IDE tools, such as Cursor or GitHub Copilot.## How to useCopy the prompt to a file in your repo.-Use the "include file" feature from your AI tool to include the prompt when chatting with your AI assistant. For example, with GitHub Copilot, use `#<filename>`, in Cursor, use `@Files`, and in Zed, use `/file`.+Use the "include file" feature from your AI tool to include the prompt when chatting with your AI assistant. For example, in Cursor, add them as [project rules](https://docs.cursor.com/context/rules-for-ai#project-rules-recommended), with GitHub Copilot, use `#<filename>`, and in Zed, use `/file`.## Promptsdiff --git a/examples/prompts/code-format-sql.md b/examples/prompts/code-format-sql.mdindex 45e55811dac..4302b639cfb 100644--- a/examples/prompts/code-format-sql.md+++ b/examples/prompts/code-format-sql.md@@ -1,4 +1,8 @@-# Postgres SQL Style Guide+---+# Specify the following for Cursor rules+description: Guidelines for writing Postgres SQL+globs: "**/*.sql"+---## Generaldiff --git a/examples/prompts/database-create-migration.md b/examples/prompts/database-create-migration.mdindex 19b987d4334..6e7513d1ce2 100644--- a/examples/prompts/database-create-migration.md+++ b/examples/prompts/database-create-migration.md@@ -1,6 +1,8 @@-<!-- SUGGESTION: include the `code-format-sql.md` prompt for coding style. -->--# Database: Create migration+---+# Specify the following for Cursor rules+description: Guidelines for writing Postgres migrations+globs: "supabase/migrations/**/*.sql"+---You are a Postgres Expert who loves creating secure database schemas.diff --git a/examples/prompts/database-functions.md b/examples/prompts/database-functions.mdindex 4eb0537566d..4117836cb76 100644--- a/examples/prompts/database-functions.md+++ b/examples/prompts/database-functions.md@@ -1,4 +1,8 @@-# Database: Create functions+---+# Specify the following for Cursor rules+description: Guidelines for writing Supabase database functions+globs: "**/*.sql"+---You're a Supabase Postgres expert in writing database functions. Generate **high-quality PostgreSQL functions** that adhere to the following best practices:diff --git a/examples/prompts/database-rls-policies.md b/examples/prompts/database-rls-policies.mdindex 8c9d63b9ae8..65d0f6ddb37 100644--- a/examples/prompts/database-rls-policies.md+++ b/examples/prompts/database-rls-policies.md@@ -1,4 +1,8 @@-# Database: Create RLS policies+---+# Specify the following for Cursor rules+description: Guidelines for writing Postgres Row Level Security policies+globs: "**/*.sql"+---You're a Supabase Postgres expert in writing row level security policies. Your purpose is to generate a policy with the constraints given by the user. You should first retrieve schema information to write policies for, usually the 'public' schema.diff --git a/examples/prompts/edge-functions.md b/examples/prompts/edge-functions.mdindex 88131194603..669824f1614 100644--- a/examples/prompts/edge-functions.md+++ b/examples/prompts/edge-functions.md@@ -1,4 +1,8 @@-# Writing Supabase Edge Functions+---+# Specify the following for Cursor rules+description: Coding rules for Supabase Edge Functions+globs: "supabase/functions/**/*.ts"+---You're an expert in writing TypeScript and Deno JavaScript runtime. Generate **high-quality Supabase Edge Functions** that adhere to the following best practices:diff --git a/examples/prompts/nextjs-supabase-auth.md b/examples/prompts/nextjs-supabase-auth.mdindex b10a4d63c3d..f9f3c2379e8 100644--- a/examples/prompts/nextjs-supabase-auth.md+++ b/examples/prompts/nextjs-supabase-auth.md@@ -1,4 +1,8 @@-# Bootstrap Next.js app with Supabase Auth+---+# Specify the following for Cursor rules+description: Guidelines for writing Next.js apps with Supabase Auth+globs: "**/*.ts, **/*.tsx, **/*.js, **/*.jsx"+---Create a Next.js app that uses App Router with Supabase Auth.