A

anishfn

Fullstack Engineer

Command Palette

Search for a command to run...

Snib

The home for every snippet you never want to lose

Snib

about

Every developer keeps a graveyard of half-remembered code: the regex that took an afternoon to get right, the shell command you look up every single time, the auth boilerplate you've rewritten a hundred ways. It always ends up scattered across gists, notes apps, and old projects you can never find again.

Snib is where that code finally settles down. Save a snippet in a keystroke, tag it, file it in a collection, and trust you can pull it back the moment you need it. Search is instant and a command palette keeps your hands on the keyboard, so finding a snippet feels closer to remembering than digging.

Shiki renders every language with the same highlighting you get inside your editor, so a saved snippet reads like real code instead of a flat block of text, and one click drops it straight onto your clipboard.

Under the hood it's a Next.js and React frontend talking to an async FastAPI backend. Auth runs on JWT with rotating refresh tokens plus GitHub and Google OAuth, folders use a closure table so deeply nested lookups stay fast, and Postgres, Redis, and Celery handle storage, sessions, and background work.

the hard part

The interesting problem was keeping deeply nested folders fast: a closure table turns recursive subtree lookups into a single indexed query, so search and navigation stay instant no matter how deep the hierarchy goes.

highlights

  • Instant full text search with a command palette
  • Editor grade syntax highlighting via Shiki
  • Collections and tags to organize snippets
  • Starred, recent, and trash views
  • One click copy to clipboard
  • Secure login with GitHub and Google OAuth

built with

Next.jsReactTypeScriptFastAPIPostgreSQLRedis