Are you an LLM? Read llms.txt for a summary of the docs, or llms-full.txt for the full context.
Skip to content

Your First Project

Build a task management app from scratch.

Project Overview

What we're building:

  • Add tasks
  • Mark tasks complete
  • Delete tasks
  • Filter by status

Tech Stack:

  • Next.js 15 + TypeScript
  • Tailwind CSS
  • Local state (no database)
  • Vitest for testing

Time: 30-45 minutes

Step 1: Initialize Project

mkdir task-manager
cd task-manager
npx create-next-app@latest . --typescript --tailwind --eslint --app --src-dir --import-alias "@/*"
npx @itz4blitz/agentful init
claude

Step 2: Define Product Specification

Edit .claude/product/index.md to define what you want to build:

# Product Specification
 
## Overview
A simple task management application for personal productivity.
 
## Goals
- [ ] Users can add tasks
- [ ] Users can mark tasks complete
- [ ] Users can delete tasks
- [ ] Users can filter tasks by status
- [ ] 80%+ test coverage
 
## Tech Stack
 
### Frontend
- Framework: Next.js 15
- Language: TypeScript
- Styling: Tailwind CSS
- State Management: React useState
 
### Testing
- Unit: Vitest
 
## Features (Priority Order)
 
### 1. Add Task - CRITICAL
**Description**: Users can add new tasks
 
**Acceptance Criteria**:
- [ ] Input field for task description
- [ ] Add button
- [ ] Task appears in list
- [ ] Input clears after adding
- [ ] Validation: empty tasks not allowed
- [ ] Validation: max 200 characters
 
**Technical Notes**:
- Use input with text type
- Show error message for invalid input
- Focus input after adding
 
### 2. Toggle Task Completion - CRITICAL
**Description**: Users can mark tasks complete/incomplete
 
**Acceptance Criteria**:
- [ ] Checkbox to toggle
- [ ] Visual indicator for completed tasks (strikethrough)
- [ ] Completion status persists
 
**Technical Notes**:
- Use checkbox element
- Add line-through style for completed
- Gray out completed task text
 
### 3. Delete Task - HIGH
**Description**: Users can delete tasks
 
**Acceptance Criteria**:
- [ ] Delete button on each task
- [ ] Task removes from list
 
**Technical Notes**:
- Use trash icon or "Delete" button
- Red color for delete action
 
### 4. Filter Tasks - MEDIUM
**Description**: Users can filter tasks by status
 
**Acceptance Criteria**:
- [ ] Filter buttons: All, Active, Completed
- [ ] Only show tasks matching filter
- [ ] Active filter highlighted
- [ ] Task count updates per filter
 
**Technical Notes**:
- Use button group for filters
- Update count when filter changes
 
### 5. Task Counter - LOW
**Description**: Display count of remaining tasks
 
**Acceptance Criteria**:
- [ ] Show "X tasks left" text
- [ ] Updates in real-time
- [ ] Only counts active (incomplete) tasks
 
## Architecture Notes
 
### Folder Structure
 
src/
├── app/
│   ├── page.tsx          # Main task manager page
│   ├── layout.tsx        # Root layout
│   └── globals.css       # Global styles
├── components/
│   ├── TaskList.tsx      # Task list component
│   ├── TaskItem.tsx      # Individual task
│   ├── TaskInput.tsx     # Add task input
│   └── TaskFilters.tsx   # Filter buttons
└── lib/
    └── types.ts          # TypeScript types
 
### Design Patterns
- TypeScript for all components
- Functional components with hooks
- Explicit props interfaces
- Separation of concerns
 
### Constraints
- Mobile-first responsive design
- Accessible (keyboard navigation, ARIA labels)
- Client-side only
- Tailwind utility classes
 
## Success Criteria
1. All critical and high features implemented
2. All tests passing with 80%+ coverage
3. No type errors
4. No lint errors
5. Responsive on mobile (375px+)
6. Accessible with keyboard

Step 3: Start Development

With your product spec defined, start the development loop:

/agentful-start

agentful will:

  1. Analyze your product spec
  2. Generate specialized agents for your stack
  3. Begin implementing features in priority order

Step 4: Watch agentful Work

agentful now works through your features automatically. Watch the terminal for progress updates. See the Overview for detailed workflow information.

You'll see:
Orchestrator planning work...
Feature queue:
1. Add Task (CRITICAL)
2. Toggle Task Completion (CRITICAL)
3. Delete Task (HIGH)
4. Filter Tasks (MEDIUM)
5. Task Counter (LOW)
 
Starting: Add Task feature
Phase 3: Implementation
Frontend Agent implementing...
Created:
- src/lib/types.ts
- src/components/TaskInput.tsx
- src/components/TaskList.tsx
- src/components/TaskItem.tsx
- src/app/page.tsx
Phase 4: Testing
Tester Agent writing tests...
Created:
- src/components/__tests__/TaskInput.test.tsx
- src/components/__tests__/TaskList.test.tsx
- src/components/__tests__/TaskItem.test.tsx
 
Running tests... 14 passing
Phase 5: Validation
Reviewer Agent validating...
TypeScript: ✓ No errors
ESLint: ✓ No errors
Tests: ✓ All passing
Coverage: ✓ 87%
 
Feature complete: Add Task (100%)

Process repeats for each feature.

Step 5: Monitor Progress

Check progress anytime:

/agentful-status

Output:

Working on: Filter Tasks feature
Phase: implementation
Iterations: 15
 
Progress: 60%
 
Features:
✓ Add Task (100%)
✓ Toggle Task Completion (100%)
✓ Delete Task (100%)
• Filter Tasks (40%)
○ Task Counter (0%)
 
Quality Gates:
✓ Tests Passing (42/42)
✓ No Type Errors
✓ Coverage 87%
 
Reading from: .claude/product/index.md

Step 6: Handle Decisions

If agentful needs input:

Decision needed:
For "Delete Task", should we:
1. Show confirmation dialog before deleting
2. Delete immediately without confirmation

Answer:

/agentful-decide

Then provide your choice:

Option 2: Delete immediately

agentful resumes immediately.

Step 7: Review Results

When complete, review:

# View structure
tree src/components
 
# Test coverage
npm run test -- --coverage
 
# Type check
npx tsc --noEmit
 
# Lint
npm run lint
 
# Run dev server
npm run dev

Open http://localhost:3000 and test all features.

What agentful Built

File Structure

src/
├── app/
│   ├── page.tsx
│   ├── layout.tsx
│   └── globals.css
├── components/
│   ├── TaskInput.tsx
│   ├── TaskList.tsx
│   ├── TaskItem.tsx
│   └── TaskFilters.tsx
├── lib/
│   └── types.ts
└── components/
    └── __tests__/
        ├── TaskInput.test.tsx
        ├── TaskList.test.tsx
        ├── TaskItem.test.tsx
        └── TaskFilters.test.tsx

Features Implemented

  • Add Task (input with validation)
  • Toggle Completion (checkbox with strikethrough)
  • Delete Task (remove button)
  • Filter Tasks (All/Active/Completed)
  • Task Counter ("X tasks left")
  • Responsive Design (mobile-first Tailwind)
  • Accessibility (keyboard navigation, ARIA)
  • Tests (48 tests, 87% coverage)

Common Issues

agentful stops mid-development

Check status:

/agentful-status

Look for:

  • Pending decisions → /agentful-decide
  • High iteration count → Check for blocking decisions
  • Errors → /agentful-validate

Tests failing

Let agentful handle it. Fixer agent will:

  1. Identify failing tests
  2. Fix implementation
  3. Re-run tests
  4. Continue when passing

TypeScript errors

Fixer agent resolves these. If persistent:

npx tsc --noEmit
# Fix manually if needed
/agentful-start  # Continue development

Customizing Your Project

Add New Features

Edit .claude/product/index.md:

### 6. Task Due Dates - MEDIUM
**Description**: Add due dates to tasks
 
**Acceptance Criteria**:
- [ ] Date picker on add task
- [ ] Display due date on task
- [ ] Sort by due date

Then:

/agentful-start

agentful will detect the new feature and work on it.

Modify Existing Features

Update acceptance criteria in .claude/product/index.md, then run /agentful-start to continue.

Add Domain Structure

For complex projects, organize into domains:

mkdir -p .claude/product/domains/tasks
mv .claude/product/index.md .claude/product/index.md.bak
# Split content into domain files

Recap

You built a complete task management app with:

  • 5 features fully implemented
  • 48 tests passing
  • 87% test coverage
  • No type errors
  • Responsive design
  • Accessibility features
  • In 30-45 minutes

Key Learnings:

  1. Intelligent Init - agentful analyzes and creates appropriate structure
  2. Product Structure - Hierarchical .claude/product/ with optional domain organization
  3. Agent Generation - /agentful-start auto-generates stack-specific agents on first run
  4. Progress Monitoring - /agentful-status shows what's being worked on
  5. Quality Automation - Tests, type checking, linting enforced automatically

Next Steps:

  • Build more complex projects with domain organization
  • Customize agentful for your specific stack
  • Deploy your project

Configuration

Modify agents and commands Configuration Guide

Deploy

Deploy to Vercel, Netlify, or your host Follow your platform's guides