| name | architecture |
| description | Understanding data flow, domain patterns, cross-domain dependencies, and architectural constraints |
Architecture Guide
For comprehensive architecture documentation, read docs/CODEBASE_OVERVIEW.md.
Key Reminders
Three-phase data pipeline:
- Init - One-time setup of domain instances and static game data
- Parse - Extract raw data from cloud save (NO cross-domain access, NO calculations)
- Calculate - Compute values in strict dependency order (cross-domain access allowed)
Critical architectural rules:
- Calculate phase requires strict ordering due to cross-domain dependencies
- Parse phase must NEVER access other domains or perform calculations
- Auto-generated directories MUST NOT be modified:
data/domain/data/, data/domain/enum/, data/domain/model/
Finding correct calculation order:
- Identify what domains your feature reads from (dependencies)
- Place your feature AFTER its dependencies
- Identify what domains might read from your feature (dependents)
- Place your feature BEFORE its dependents
- Test thoroughly - wrong order breaks everything
Data sync command:
cp -r ../IdleonWikiBot/exported/ts/* data/domain/
Known fragility:
- Order maintained manually (no dependency graph)
- Mixed patterns from learning TS/React over time
- Hard to parallelize due to sequential pipeline