vercel-known-pitfalls

Featured

Identify and avoid Vercel anti-patterns and common integration mistakes. Use when reviewing Vercel code for issues, onboarding new developers, or auditing existing Vercel deployments for best practice violations. Trigger with phrases like "vercel mistakes", "vercel anti-patterns", "vercel pitfalls", "vercel what not to do", "vercel code review".

AI & Automation 2,926 stars 433 forks Updated yesterday MIT

Install

View on GitHub

Quality Score: 99/100

Stars 20%
100
Recency 20%
100
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
50
License 10%
100
Description 5%
100

Skill Content

# Vercel Known Pitfalls ## Overview Catalog of the most common Vercel anti-patterns with severity ratings, detection methods, and fixes. Organized by category: secret exposure, serverless function mistakes, edge runtime violations, configuration errors, and cost traps. ## Prerequisites - Access to Vercel codebase for review - Understanding of Vercel's deployment model - Familiarity with `vercel-common-errors` for error codes ## Instructions ### Category 1: Secret Exposure (Critical) **P1: Secrets in NEXT_PUBLIC_ variables** ```typescript // BAD — exposed in client JavaScript bundle, visible to anyone const apiKey = process.env.NEXT_PUBLIC_API_SECRET; // This value is inlined at build time into the browser bundle // GOOD — server-only access const apiKey = process.env.API_SECRET; // Only accessible in serverless functions and server components ``` - **Detection:** `grep -r 'NEXT_PUBLIC_.*SECRET\|NEXT_PUBLIC_.*KEY\|NEXT_PUBLIC_.*TOKEN' src/` - **Fix:** Remove `NEXT_PUBLIC_` prefix, rotate the exposed secret immediately **P2: Hardcoded credentials in source** ```typescript // BAD const client = new Client({ apiKey: 'sk_live_abc123' }); // GOOD const client = new Client({ apiKey: process.env.API_KEY }); ``` - **Detection:** `grep -rE 'sk_live|sk_test|Bearer [a-zA-Z0-9]{20,}' src/ api/` - **Fix:** Move to environment variables, add pre-commit hook **P3: Secrets in vercel.json** ```json // BAD — vercel.json is committed to git { "env": { "API_KEY": "sk_live_abc123" } } ...

Details

Author
jeremylongshore
Repository
jeremylongshore/claude-code-plugins-plus-skills
Created
1 years ago
Last Updated
yesterday
Language
Python
License
MIT

Integrates with

Bundled in these plugins

Similar Skills

Semantically similar based on skill content — not just same category