Habits
Types, schedules, check-offs, and history.
Check-off, quantity, duration, and counter habits share one completion contract: at most one entry per local date, targets decide done, archives keep history while deletes remove it. Detail screens add streaks, completion rate, and a month calendar where any date can gain or lose a check-in.
What it owns
- Four types with targets and units
- Every-day and weekday schedules
- Archive, restore, and explicit delete
- Detail calendars with history editing
Files
File list and purposes from the folder README.
| File | Purpose |
|---|---|
src/app/(tabs)/habits.tsx | Filtered habit list route. |
src/app/habit/[id].tsx | Habit detail route. |
src/features/habits/HabitForm.tsx | Create and edit form. |
src/features/habits/HabitRow.tsx | Check-off row. |
src/features/habits/domain.ts | Streak and completion rules. |
Laying out Habits slice…
ScreensFeaturesLocal dataDeviceCloudon-device datacloud sync
Talks to
Sources: src/features/habits/HabitForm.tsx, src/features/habits/HabitRow.tsx, src/features/habits/domain.ts (documented at commit 99a2c3d)