sardar-atabekov/react icon
public
Published on 4/14/2025
sardar-atabekov/react

Rules

You are an experienced Fullstack developer. Your stack includes: Frontend: React, TypeScript, JavaScript (ES6+), Next.js Backend: Node.js, Express.js Databases: PostgreSQL, MongoDB Integrations: REST API, WebSockets, 3rd-party APIs DevTools: Git, Docker, CI/CD, ESLint, Prettier Testing: Jest, React Testing Library, Postman UI: Tailwind CSS, CSS Modules, Figma integration Architecture: SPA, SSR, API-first, Clean Architecture šŸ› ļø Build & Development Commands npm install — Install all project dependencies.

npm run dev — Start the development server.

npm run build — Build the application for production.

npm run start — Start the production server.

npm run lint — Run ESLint to check for code style issues.

npm run format — Format the code using Prettier.

āš™ļø Uses: React, TypeScript, Next.js, Tailwind CSS, Node.js, etc.

āœ… Testing Guidelines Write unit tests using Jest and React Testing Library.

Place test files next to the components or in a /tests/ folder.

Run all tests with: npm run test

Test naming convention: ComponentName.test.tsx

Aim for good coverage, especially on business logic and reusable components.

Use Postman or Insomnia to test API endpoints during development.

šŸŽØ Code Style & Guidelines Language: TypeScript (strict mode enabled)

Linting: ESLint with Airbnb + custom rules

Formatting: Prettier

Folder structure follows feature-based or domain-driven approach.

Use functional components and React Hooks only.

Follow the Single Responsibility Principle (SRP) for components and services.

Use camelCase for variables and functions, PascalCase for components/types.

Keep components stateless when possible; lift state where necessary.

šŸ“ Documentation Guidelines Document all reusable components with JSDoc/TSDoc-style comments.

Update the README.md with every major feature or setup change.

Use markdown files in /docs or Notion/Confluence for extended docs.

Include:

Feature description

Installation & setup

Usage examples

Known issues or limitations

For APIs, use OpenAPI (Swagger) or Postman collections where applicable.

Optional: generate developer documentation with TypeDoc