Before you begin, ensure you have the following installed:
- Node.js (v18 or higher)
- npm or yarn package manager
- Git for version control
git clone https://github.com/Mayur-Pagote/README_Design_Kit.git
cd README_Design_Kitnpm installnpm run devThe application will be available at http://localhost:5174
| Script | Description |
|---|---|
npm run dev |
Start development server with hot reloading |
npm run build |
Build the application for production |
npm run preview |
Preview the production build locally |
npm run lint |
Run ESLint to check code quality |
-
VS Code Extensions (Recommended):
- ES7+ React/Redux/React-Native snippets
- TypeScript Importer
- Tailwind CSS IntelliSense
- Prettier - Code formatter
- ESLint
-
Browser Extensions (Optional):
- React Developer Tools
- Redux DevTools (if using Redux)
The project uses ESLint for code quality. Run linting with:
npm run lintsrc/
├── components/ # Reusable UI components
│ ├── ui/ # Base UI components (buttons, inputs, etc.)
│ ├── Layout.tsx # Page layout wrapper
│ └── ...
├── pages/ # Route components
├── hooks/ # Custom React hooks
├── lib/ # Utility functions
├── config/ # Application configuration
├── types/ # TypeScript type definitions
└── theme/ # Theme configuration
- Use TypeScript for all components
- Follow the existing naming conventions
- Include proper props typing
- Add JSDoc comments for complex components
Example component structure:
import { type ComponentProps } from 'react'
interface MyComponentProps {
title: string
isActive?: boolean
}
export function MyComponent({ title, isActive = false }: MyComponentProps) {
return (
<div className="p-4">
<h2>{title}</h2>
</div>
)
}- Use Tailwind CSS utility classes
- Follow the established design system
- Use CSS variables for theme values
- Prefer composition over inheritance
- Use React hooks for local state
- Use React Query for server state
- Keep state as close to where it's used as possible
- Test all routes work correctly
- Verify responsive design on different screen sizes
- Test drag and drop functionality
- Ensure theme switching works
- Validate form inputs
Test the application in:
- Chrome (latest)
- Firefox (latest)
- Safari (latest)
- Edge (latest)
Before deploying, always test the production build locally:
npm run build
npm run previewThe project is configured for automatic deployment to Vercel:
- Push changes to the main branch
- Vercel automatically builds and deploys
- Check the deployment logs for any issues
-
Port already in use
# Kill process using port 5174 npx kill-port 5174 -
Node modules issues
# Clear node_modules and reinstall rm -rf node_modules package-lock.json npm install -
TypeScript errors
# Check TypeScript compilation npx tsc --noEmit -
Build failures
# Clear Vite cache rm -rf dist npm run build
- Check the Issues page
- Read the Contributing Guidelines
- Join our community discussions
After setting up the project:
- Explore the codebase structure
- Try making small changes to understand the workflow
- Read the Files Documentation for detailed component information
- Check out open issues to start contributing