-
Notifications
You must be signed in to change notification settings - Fork 0
Contributing
Thank you for considering contributing to ɳTasks! This document outlines the guidelines for contributing.
Be respectful, inclusive, and constructive in all interactions.
- Check if the bug has already been reported in Issues
- If not, create a new issue with:
- Clear title and description
- Steps to reproduce
- Expected vs actual behavior
- Backend provider being used
- Screenshots if applicable
- Environment details (OS, Node version, etc.)
- Check Discussions for existing suggestions
- Create a new discussion with:
- Clear use case
- Proposed implementation (if you have ideas)
- Benefits to users
- Potential challenges
-
Fork the repository
git clone https://github.com/nself-org/ntask.git cd ntask -
Create a feature branch
git checkout -b feature/your-feature-name
-
Make your changes
- Follow the existing code style
- Add tests if applicable
- Update documentation
- Keep commits focused and atomic
-
Test your changes
npm run build npm run typecheck npm run lint
-
Test with multiple backends Test your changes with different backend providers:
-
EXPO_PUBLIC_HASURA_URL=http://localhost:8080/v1/graphql(mobile) -
VITE_HASURA_URL=http://localhost:8080/v1/graphql(web SaaS)
-
-
Commit your changes
git add . git commit -m "feat: add amazing feature"
Use conventional commit messages:
-
feat:- New feature -
fix:- Bug fix -
docs:- Documentation changes -
style:- Code style changes (formatting, etc.) -
refactor:- Code refactoring -
test:- Adding or updating tests -
chore:- Maintenance tasks
-
-
Push to your fork
git push origin feature/your-feature-name
-
Create a Pull Request
- Go to the original repository
- Click "New Pull Request"
- Select your feature branch
- Fill out the PR template
- Link related issues
- Use TypeScript strict mode
- Follow existing patterns in the codebase
- Use functional components with hooks
- Keep files under 300 lines when possible
- Use Tailwind CSS for styling
- No inline styles
NEVER import backend SDKs directly. Always use the abstraction layer:
// ❌ BAD
import { createClient } from '@supabase/supabase-js';
// ✅ GOOD
import { useAuth } from '@/lib/providers';'use client';
import { useState, useEffect } from 'react';
import { useAuth } from '@/lib/providers';
export function MyComponent() {
// 1. Hooks
const { user } = useAuth();
const [state, setState] = useState();
// 2. Functions
function handleClick() {}
// 3. Effects
useEffect(() => {}, []);
// 4. Render
return <div>...</div>;
}components/
feature-name/
main-component.tsx
sub-component.tsx
types.ts
utils.ts
- Test with all backend providers
- Test responsive design (mobile, tablet, desktop)
- Test dark/light themes
- Test offline functionality if applicable
- Test error states
- Update README.md if adding features
- Add JSDoc comments for complex functions
- Update BACKEND.md if changing backend logic
- Include examples in comments
- Create adapter directory:
lib/backend/new-provider/ - Implement all interfaces from
lib/types/backend.ts - Add to factory in
lib/backend/index.ts - Add config to
lib/config.ts - Add env vars to
.env.example - Document in BACKEND.md
- Add to
AuthMethodtype inlib/auth-config.ts - Add default config in
DEFAULT_METHODS - Add icon in
components/auth/social-auth-button.tsx - Update docs
- Create in
hooks/use-[name].ts - Export from
hooks/index.ts - Add JSDoc comments
- Add example in README.md
Use shadcn/ui components when possible:
npx shadcn-ui@latest add [component-name]For custom components:
- Create in
components/[feature]/ - Use existing UI components as building blocks
- Make it responsive
- Support dark mode
- Maintainers will review your PR
- Address any feedback
- Once approved, maintainer will merge
- Your contribution will be credited in release notes
- Check existing Issues
- Join Discussions
- Read README.md and BACKEND.md
By contributing, you agree that your contributions will be licensed under the MIT License.
Thank you for contributing to ɳTasks!
Getting Started
Features
CLI & Agents
Backend
Architecture
Deployment
Reference
External