An open API service indexing awesome lists of open source software.

https://github.com/jonghyo/roo-twitter


https://github.com/jonghyo/roo-twitter

Last synced: 5 months ago
JSON representation

Awesome Lists containing this project

README

          

# Next.js Template for RooCode AI Development [![build status](https://github.com/jonghyo/nextjs-roocode-template/actions/workflows/ci.yml/badge.svg?branch=main)](https://github.com/jonghyo/nextjs-roocode-template/actions/workflows/ci.yml)

This is a specialized Next.js template designed for AI-powered code generation using RooCode. It includes comprehensive configuration files and development rules to maximize the effectiveness of AI-assisted development.

## ๐Ÿค– RooCode Integration

This template comes pre-configured with essential files for RooCode AI development:

- `.clinerules` - Defines technical stack, development workflows, and coding standards for AI
- `.roomodes` - Configures custom AI modes for different development tasks
- Pre-configured development workflows optimized for AI collaboration
- Automated code quality checks and formatting rules that align with AI-generated code

## Features

- ๐ŸŽฏ Optimized for AI-assisted development with RooCode
- ๐Ÿš€ [Next.js](https://nextjs.org/) with App Router for robust routing and server-side rendering
- ๐Ÿ’Ž [TypeScript](https://www.typescriptlang.org/) for type safety
- ๐ŸŽจ [shadcn/ui](https://ui.shadcn.com/) + [Tailwind CSS](https://tailwindcss.com/) for beautiful, customizable UI components
- ๐Ÿ“ฆ [Zustand](https://github.com/pmndrs/zustand) for state management
- ๐Ÿงช [Vitest](https://vitest.dev/) + [React Testing Library](https://testing-library.com/docs/react-testing-library/intro/) for testing
- ๐Ÿ“š [Storybook](https://storybook.js.org/) for component documentation
- โœจ [ESLint](https://eslint.org/) and [Prettier](https://prettier.io/) for code quality
- ๐Ÿ” Pre-commit hooks with [lefthook](https://github.com/evilmartians/lefthook)
- ๐Ÿ› ๏ธ Additional tools and libraries:
- [Zod](https://zod.dev/) for schema validation
- [React Hook Form](https://react-hook-form.com/) for form management
- Day.js for date handling
- NextAuth.js for authentication
- [Pino](https://github.com/pinojs/pino) for logging
- MSW for API mocking
- Playwright for E2E testing

## AI Development Configuration

### .clinerules

The `.clinerules` file defines:

- Technical stack specifications
- Development workflow phases
- Coding standards and best practices
- Testing requirements
- Security guidelines

### .roomodes

Custom AI modes for different development tasks:

- PM Mode: Project management and requirements definition
- Architect Mode: System design and architecture planning
- Code Mode: Implementation and testing
- Debug Mode: Problem diagnosis and resolution

## Getting Started

### Prerequisites

- Node.js (LTS version)
- npm
- RooCode extension installed in VS Code

### Installation

1. Clone the repository:

```bash
git clone
cd nextjs-roocode-template
```

2. Install dependencies:

```bash
npm ci
```

3. Copy the environment file:

```bash
cp .env.example .env
```

4. Start the development server:

```bash
npm run dev
```

Visit [http://localhost:3000](http://localhost:3000) to see your application.

## Available Scripts

- `npm run dev` - Start development server
- `npm run build` - Build for production
- `npm run start` - Start production server
- `npm run lint` - Run ESLint
- `npm run format` - Format code with Prettier
- `npm test` - Run tests with Vitest
- `npm run test:coverage` - Generate test coverage report
- `npm run storybook` - Start Storybook development server
- `npm run tsc` - Check TypeScript types

## Project Structure

```bash
src/
โ”œโ”€โ”€ __mocks__/ # Mock definitions
โ”œโ”€โ”€ __tests__/ # Test files
โ”œโ”€โ”€ app/ # Next.js App Router files
โ”œโ”€โ”€ components/ # React components
โ”‚ โ”œโ”€โ”€ features/ # Feature-specific components
โ”‚ โ”œโ”€โ”€ layout/ # Layout components
โ”‚ โ””โ”€โ”€ ui/ # Base UI components
โ”œโ”€โ”€ env/ # Environment variables definition for t3-env
โ””โ”€โ”€ lib/ # Utility functions and shared logic
```

## Development Guidelines

- Follow the development workflow defined in `.clinerules`
- Utilize appropriate AI modes for different development tasks
- Follow the TypeScript coding standards
- Write comprehensive tests for new features
- Update Storybook documentation for UI components
- Ensure ESLint and Prettier rules are followed
- Use shadcn/ui components when possible
- Follow the commit message convention

## Contributing

1. Create a feature branch from `main`
2. Make your changes following the AI development guidelines
3. Run tests and ensure all checks pass
4. Submit a pull request to `main`

## License

This project is licensed under the Apache-2.0 License - see the [LICENSE](LICENSE) file for details.