Welcome to the Bug-Free Sniffle repository! This project is built with Next.js 15, React 19, and Tailwind CSS v4.
This document outlines the required setup and workflow for all contributors to ensure a smooth, consistent, and high-quality development process for our team.
- Node.js:
v22.0.0or higher. We recommend using nvm (an.nvmrcfile is included). - Package Manager:
npm(v10+). Do not use Yarn, pnpm, or bun to avoid lockfile conflicts (enforced via package.json engines).
-
Fork & Clone the repository:
- First, click the Fork button at the top right of this repository to create your own copy.
- Then, clone your forked repository:
git clone https://github.com/<your-username>/bug-free-sniffle.git cd bug-free-sniffle
- (Optional but recommended) Add the original repository as an upstream remote to keep your fork synced:
git remote add upstream https://github.com/<upstream-org>/bug-free-sniffle.git
-
Use the correct Node version:
nvm use
-
Install dependencies: (This will automatically initialize the Husky Git hooks)
npm ci
-
Environment Variables: If an
.env.examplefile exists, copy it to.env.localand fill in the required values. (Note: Never commit.env.local!) -
Start the development server:
npm run dev
Open http://localhost:3000 with your browser to see the app.
We highly recommend using Visual Studio Code. When you open this project, VS Code will prompt you to install Recommended Extensions (Prettier, ESLint, Tailwind CSS). Please install them.
Our workspace settings (.vscode/settings.json) are configured to automatically:
- Format your code with Prettier on save.
- Fix ESLint errors on save.
- Provide Tailwind IntelliSense inside custom utilities like
cn()andcva().
To maintain code quality across the team, we enforce strict linting, formatting, and commit standards.
Always sync your local main with the upstream repository before starting. Then, create a new branch on your fork for your work:
git checkout -b feature/your-feature-name
# or
git checkout -b fix/your-bugfix-nameWe use Conventional Commits. Your commit messages must follow this format, or Husky will reject the commit:
<type>: <description>
# Examples:
feat: add user authentication form
fix: resolve mobile layout overflow on navbar
docs: update readme instructions
chore: update npm dependencies
(Allowed types: feat, fix, docs, style, refactor, perf, test, build, ci, chore, revert)
git commit, our lint-staged hook will automatically format your files with Prettier and check them with ESLint. If there are unfixable errors, your commit will be aborted.
- Push your feature branch to your forked repository on GitHub.
- Go to the original upstream repository and click New Pull Request.
- Compare your fork's branch against the upstream
mainbranch. - Fill out the provided PR Template completely.
- Ensure all GitHub Action CI checks pass (formatting, linting, and Next.js build tests).
- Request a review from at least one other team member.
- Once approved and checks pass, the maintainers will squash and merge your PR.
npm run dev: Starts the development server using Turbopack.npm run build: Builds the application for production.npm start: Starts the production server.npm run lint: Runs ESLint to catch errors across the project.npm run format: Manually formats all codebase files using Prettier.npm run format:check: Verifies formatting (used by CI).npm run typecheck: Runs the TypeScript compiler to check for type errors without emitting files.
Happy coding! 🎉