Documentation Index
Fetch the complete documentation index at: https://mintlify.com/Fireinthebellyy/ftb-web/llms.txt
Use this file to discover all available pages before exploring further.
Prerequisites
Before you begin, ensure you have the following installed:- Node.js: Version 20 or higher
- Package Manager: npm, yarn, pnpm, or bun
- PostgreSQL: A PostgreSQL database (we recommend Neon for serverless PostgreSQL)
- Git: For version control
Installation
Configure environment variables
Create a
.env.local file in the root directory with the following variables:Most third-party services offer free tiers for development. Check their respective documentation for obtaining API keys.
Start the development server
Launch the Next.js development server with Turbopack:The application will be available at http://localhost:3000
Development Commands
Here are the most commonly used npm scripts:| Command | Description |
|---|---|
npm run dev | Start development server with Turbopack |
npm run build | Build for production |
npm start | Start production server |
npm run lint | Run ESLint for code quality checks |
npm run test | Run Vitest unit tests |
npm run test:ui | Run tests with Vitest UI |
npm run dz:generate | Generate Drizzle migrations |
npm run dz:push | Push schema changes to database |
npm run dz:pull | Pull schema from database |
npm run clean | Clean build artifacts and cache |
Code Formatting
FTB Hustle uses Prettier for code formatting with Tailwind CSS plugin:Troubleshooting
Database connection errors
Database connection errors
- Verify your
DATABASE_URLis correct - Ensure your PostgreSQL database is running
- Check if your database accepts connections from your IP
- For Neon, verify you’re using the correct connection string format
Authentication not working
Authentication not working
- Ensure
BETTER_AUTH_SECRETis set - Verify OAuth credentials (Google, LinkedIn) are correct
- Check if redirect URIs are properly configured in OAuth providers
- Confirm email service (Resend) credentials are valid
Build errors
Build errors
- Run
npm run cleanto clear cache - Delete
node_modulesand reinstall:rm -rf node_modules && npm install - Check for TypeScript errors:
npx tsc --noEmit
Environment variables not loading
Environment variables not loading
- Ensure file is named
.env.local(not.env) - Restart the development server after changing environment variables
- Check for syntax errors in your
.env.localfile
Next Steps
Once your development environment is set up:- Review the Architecture to understand the codebase structure
- Explore the Tech Stack to learn about key dependencies
- Check out the API Reference for backend endpoints