Developer Setup Guide
Prerequisites
Before setting up the development environment, ensure you have the following installed:
- Node.js (version 18 or higher)
- npm or yarn
- Git
- Docker (optional, for local development)
- VS Code or preferred IDE
Getting Started
1. Clone the Repository
git clone https://github.com/your-org/learnille.git
cd learnille
2. Install Dependencies
# Install root dependencies
npm install
# Install server dependencies
cd server
npm install
# Install client dependencies
cd ../client
npm install
3. Environment Setup
Create environment files:
# Copy environment templates
cp server/.env.example server/.env
cp client/.env.example client/.env
Update the .env files with your local configuration.
4. Database Setup
# Start database (if using Docker)
docker-compose up -d
# Run migrations
cd server
npm run migration:run
5. Start Development Servers
# Start server
cd server
npm run start:dev
# Start client (in new terminal)
cd client
npm run dev
Development Workflow
Running Tests
# Run all tests
npm test
# Run tests in watch mode
npm run test:watch
# Run e2e tests
npm run test:e2e
Code Quality
# Run linter
npm run lint
# Fix linting issues
npm run lint:fix
# Run type checking
npm run typecheck
IDE Configuration
VS Code Extensions
- TypeScript and JavaScript Language Features
- Prettier
- ESLint
- GitLens
- Docker (if using containers)
Settings
Add to your VS Code settings:
{
"editor.formatOnSave": true,
"editor.defaultFormatter": "esbenp.prettier-vscode",
"typescript.preferences.importModuleSpecifier": "relative"
}
Troubleshooting
Common Issues
- Port conflicts: Change ports in
.envfiles - Database connection: Ensure Docker is running
- Dependencies: Clear node_modules and reinstall
- Permissions: Check file permissions for scripts
Getting Help
- Check existing issues on GitHub
- Review documentation in
/docs - Contact the development team
Next Steps
- Read the coding standards
- Review the version control policy
- Familiarize yourself with the project structure
- Start with a small feature or bug fix