A
DATABASE // LEVEL_UP
SKILLS_V1.0
RETURN
NICE-TO-HAVE SKILLS

LEVEL_UP

Skills that will make your vibe coding journey smoother. Not required to start, but they will save you headaches down the road.

8 TOPICS PRACTICAL EXAMPLES COPY-PASTE READY
01 // DEPENDENCY_FIX

npm i --legacy-peer-deps

ESSENTIAL

WHEN_TO_USE

When you run npm install and get scary errors about "peer dependency conflicts" or "ERESOLVE unable to resolve dependency tree."

WHAT_ARE_PEER_DEPS?

Peer dependencies are packages that say "I need package X, but YOU should install it." It is like a recipe saying "bring your own eggs." Sometimes two packages disagree on which version of eggs they want.

WHY_THIS_EXISTS

npm v7+ became stricter about dependency conflicts. Older tutorials and packages were written for npm v6 which was more lenient. The --legacy-peer-deps flag tells npm to behave like the old version.

TERMINAL
# When normal install fails:
npm install

# Try this instead:
npm install --legacy-peer-deps

# Or for a specific package:
npm install react-router-dom --legacy-peer-deps
CAUTION

This flag ignores version warnings. It usually works fine, but occasionally causes subtle bugs. If something acts weird later, dependency conflicts might be why.

PRO_TIP

If you always need this flag, create a file called .npmrc in your project with: legacy-peer-deps=true

02 // FILE_EXCLUSION

.gitignore

SECURITY

WHAT_SHOULD_NEVER_BE_TRACKED

  • Secrets: API keys, passwords, tokens (.env files)
  • Dependencies: node_modules (reinstall with npm install)
  • Build outputs: dist/, build/, .next/
  • OS junk: .DS_Store, Thumbs.db
  • Editor files: .vscode/, .idea/

HOW_TO_ADD_FILES

Create a file named .gitignore in your project root (the main folder of your project). Add one pattern per line. Files matching these patterns will be invisible to Git.

.gitignore // TEMPLATE
# Dependencies
node_modules/
vendor/

# Environment & Secrets
.env
.env.local
.env*.local
*.pem

# Build outputs
dist/
build/
.next/
out/

# OS files
.DS_Store
Thumbs.db

# Editor directories
.vscode/
.idea/
*.swp

# Logs
*.log
npm-debug.log*

# Cache
.cache/
.parcel-cache/
CRITICAL

If you already committed a secret, adding it to .gitignore will NOT remove it from history. You will need to rotate that secret and treat it as compromised.

03 // VERSION_CONTROL

Basic Git commands

CORE_SKILL
VISUAL_WORKFLOW:
clone
make changes
add
commit
push
Later: pull to get updates from others
git clone

Download a project to your computer

git clone https://github.com/user/repo.git
git pull

Get the latest changes from GitHub

git pull origin main
git status

See what files have changed

git status
git add .

Stage all changes for commit

git add . # or specific file: git add filename.js
git commit

Save changes with a message

git commit -m "Add login button"
git push

Upload commits to GitHub

git push origin main
REMEMBER

The typical flow: git add . then git commit then git push. Always pull before you start working to avoid conflicts.

04 // DATA_LAYER

DB schemas / SQL basics

SITUATIONAL

WHAT_IS_A_SCHEMA?

A schema is the structure definition for your database. It defines what tables exist, what columns each table has, and what type of data goes in each column (text, number, date, etc.).

WHEN_YOU_NEED_THIS

  • Building apps that store user data
  • Querying existing databases for stories
  • Working with government data dumps

TOOLS_THAT_HELP

ORMs (Object-Relational Mappers) let you write database code without raw SQL:

Prisma Drizzle SQLAlchemy Sequelize
BASIC_SQL_COMMANDS:
# Get data
SELECT * FROM articles WHERE year = 2024;

# Get specific columns
SELECT title, author FROM articles;

# Add data
INSERT INTO articles (title, author)
VALUES ('My Story', 'Jane Doe');

# Update data
UPDATE articles
SET status = 'published'
WHERE id = 123;

# Delete data
DELETE FROM articles WHERE id = 123;

# Count things
SELECT author, COUNT(*) as total
FROM articles
GROUP BY author;
VIBE_CODER_TIP

You do not need to memorize SQL. Describe what you want to the AI: "Get me all articles from 2024, grouped by author, showing how many each wrote." The AI will write the query.

05 // SECURITY_LAYER

Auth basics

USE_LIBRARIES

KEY_CONCEPTS_SIMPLIFIED

Users

Stored in database: email, hashed password (never plain text!), profile info

Sessions

"You are logged in" state. Server remembers who you are between page loads.

Tokens

A secret string that proves identity. Like a VIP wristband at an event.

JWT_VS_SESSION_COOKIES

- Session Cookies JWT Tokens
Storage Server remembers Client carries proof
Good for Traditional websites APIs, mobile apps
Complexity Simpler More flexible
WHY_AUTH_IS_TRICKY

Security mistakes can expose user data. Password reset flows, session expiry, CSRF attacks, and more. One bug can compromise everything.

USE_AUTH_LIBRARIES

Do NOT build auth from scratch. Use battle-tested solutions:

Auth.js Clerk Supabase Auth Firebase Auth
06 // VOCABULARY

Common dev jargon

REFERENCE
<div>
Container / Box

An invisible box that groups content together. Like a folder in a filing cabinet. Most HTML layouts are divs inside divs.

Component
Reusable Piece

A self-contained piece of UI you can reuse. Build a Button component once, use it 100 times. Change it once, updates everywhere.

Modal
Popup Dialog

A popup box that appears on top of everything else, usually dimming the background. "Are you sure you want to delete?" is typically a modal.

Card
Content Container

A visual container with borders/shadows that groups related content. Product listings, user profiles, and article previews are often cards.

Props
Data Passed Down

Data you pass to a component. Like function arguments. <Button color="blue"> - "color" is a prop with value "blue".

State
Data That Changes

Data that can change and causes the UI to update. A counter value, whether a menu is open, form input values - all state.

API
Data Interface

A way for programs to talk to each other. Your app asks an API for data, the API responds with a structured answer.

Endpoint
API Address

A specific URL in an API. /api/users might return users, /api/articles returns articles. Each is an endpoint.

Callback
Function Passed In

"Run this function when something happens." onClick, onSubmit, onSuccess - these all take callbacks. It is code waiting to execute.

07 // DOCUMENTATION

Reading docs instead of guessing

SKILL_UNLOCK

WHERE_TO_FIND_DOCS

  • Official sites: docs.react.dev, nextjs.org/docs, tailwindcss.com/docs
  • GitHub README: Most packages have docs in their repo
  • npm page: npmjs.com/package/[name] links to docs

HOW_TO_READ_THEM

  1. Start with "Getting Started" or "Quick Start"
  2. Look for code examples - copy and modify them
  3. Use Ctrl+F to search for what you need
  4. Read the API reference when you need specifics
  5. Check the changelog for recent changes

HIERARCHY_OF_TRUST

1
Official documentation
2
GitHub issues/discussions
3
Stack Overflow (check the date!)
4
Random blog posts / tutorials
WHEN_STACK_OVERFLOW_HELPS

Great for specific error messages and edge cases. But always check the date - a 2019 answer for React might be completely outdated. Look for recent answers or comments saying "this still works in 2024."

WARNING

YouTube tutorials and Medium posts go stale fast. A "React tutorial" from 2021 might teach patterns that are now anti-patterns. Always cross-reference with official docs.

08 // AI_PROMPTING

Asking AI better questions

MULTIPLIER

THE_FORMULA

"I tried X"
+
"Expected Y"
+
"Got Z"

This simple structure gives the AI everything it needs to help you debug.

INCLUDE_IN_YOUR_PROMPTS

CONTEXT

"I am building a Next.js 14 app with App Router and Tailwind..."

ERROR_MESSAGES

Copy the full error. Do not paraphrase. Include stack traces.

TECH_STACK

"Using React 18, TypeScript, Prisma with PostgreSQL..."

WHAT_YOU_TRIED

"I already tried clearing cache, reinstalling node_modules..."

BAD_PROMPT

"My code does not work. Can you fix it?"

GOOD_PROMPT

"I am building a Next.js 14 app. When I click the submit button, I expect the form data to POST to /api/contact, but instead I get a 405 Method Not Allowed error. Here is my form component and API route: [code]. I tried adding method: 'POST' explicitly but same error."

POWER_MOVES
  • - Share your package.json versions
  • - Include relevant file structure
  • - Mention your OS (Mac/Windows/Linux)
  • - Say what behavior you want, not just what is broken

Ready to level up?

These skills are not required to start vibe coding, but learning them will make you faster and more confident.

BACK TO VIBE CODING GUIDE