A modern, full-stack code snippet management application built with React, TypeScript, Convex, and Tailwind CSS. Organize your code snippets and notes in customizable spaces with professional syntax highlighting and a beautiful dark/light theme.
- Create and organize snippets/notes in custom spaces
- 3-column responsive grid layout for space cards
- Real-time content counts with badges
- Beautiful animations and hover effects
- Professional syntax highlighting for 20+ languages
- Numbered lines with proper styling
- Theme-aware code blocks (dark/light modes)
- One-click copy functionality with visual feedback
- Support for JavaScript, TypeScript, Python, Ruby, and more
- Rich text notes alongside code snippets
- Full-text search capabilities
- Tag-based organization
- Project categorization
- Vercel-inspired theme with dark mode by default
- shadcn/ui components for consistent design
- Responsive design that works on all devices
- Professional typography with Geist font family
- Smooth animations and micro-interactions
- Secure email/password authentication
- No anonymous access for better security
- Modern sign-in/sign-up forms with loading states
- Full-text search across snippets and notes
- Filter by language, project, or tags
- Advanced indexing with Convex search
- Node.js 18+
- pnpm (recommended) or npm
- A Convex account (free at convex.dev)
-
Clone the repository
git clone <repository-url> cd snippets-manager
-
Install dependencies
pnpm install
-
Set up Convex
npx convex dev
Follow the prompts to create a new Convex project or connect to an existing one.
-
Start the development server
pnpm dev
This will start both the frontend (Vite) and backend (Convex) servers.
-
Open your browser Navigate to
http://localhost:5173
to see the application.
For production deployment instructions, see DEPLOYMENT.md.
Quick deployment:
# Set up production environment (see DEPLOYMENT.md)
export $(cat .env.production | xargs)
# Deploy to production
pnpm run deploy:prod
Note: Production deployment keys are never committed to git for security.
- React 19 - Latest React with concurrent features
- TypeScript 5.7 - Type-safe development
- Vite 6 - Fast build tool and dev server
- Tailwind CSS 4 - Utility-first CSS framework
- shadcn/ui - High-quality React components
- react-syntax-highlighter - Professional code highlighting with Prism.js 1.30.0
- Geist Font - Modern typography
- Convex - Real-time backend-as-a-service
- Convex Auth - Secure authentication system
- Real-time subscriptions - Live data updates
- Full-text search - Advanced search capabilities
- ESLint - Code linting
- Prettier - Code formatting
- TypeScript - Static type checking
- Vite - Fast development and building
βββ src/
β βββ components/ # React components
β β βββ ui/ # shadcn/ui components
β β βββ CodeBlock.tsx # Syntax highlighting component
β β βββ SpaceSelector.tsx
β β βββ SnippetDetail.tsx
β βββ hooks/ # Custom React hooks
β βββ lib/ # Utility functions
β βββ App.tsx # Main application component
βββ convex/ # Backend functions and schema
β βββ auth.ts # Authentication configuration
β βββ schema.ts # Database schema
β βββ snippets.ts # Snippet-related functions
β βββ notes.ts # Note-related functions
β βββ spaces.ts # Space management functions
βββ public/ # Static assets
- Click the "Create New Space" card on the main dashboard
- Enter a name and optional description
- Start adding snippets and notes to your space
- Select a space or create a new one
- Click "Add Snippet"
- Fill in the title, select language, and paste your code
- Add tags and project information for better organization
- Save and enjoy syntax highlighting with line numbers
- Search: Use the search bar to find snippets/notes by title or content
- Filter: Filter by language, project, or tags
- Edit: Click the edit button on any snippet/note to modify
- Copy: One-click copy functionality for all code snippets
- Delete: Remove unwanted content with confirmation
Create a .env.local
file in the root directory:
# Convex deployment URL (automatically set by `npx convex dev`)
VITE_CONVEX_URL=your_convex_deployment_url
The application uses Tailwind CSS with custom color tokens. You can modify the theme in:
src/index.css
- CSS custom properties for colorstailwind.config.js
- Tailwind configuration
The application is fully responsive and works great on:
- Desktop - Full 3-column layout with all features
- Tablet - 2-column layout with optimized spacing
- Mobile - Single column with touch-friendly interactions
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature
) - Commit your changes (
git commit -m 'Add amazing feature'
) - Push to the branch (
git push origin feature/amazing-feature
) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
- Convex - For the amazing real-time backend platform
- shadcn/ui - For the beautiful component library
- Vercel - For design inspiration
- Tailwind CSS - For the utility-first CSS framework
If you have any questions or need help:
- Check the Convex documentation
- Join the Convex Discord community
- Open an issue in this repository
Built with β€οΈ by dazeb using Convex