Developers / 01
Architecture
TARAflow is an Electron desktop application with a React/TypeScript frontend. The codebase is organized into feature modules with strict import boundaries.
01
Stack
- Electron (main process) — native OS integration, keytar for credential storage, file I/O, git, tracker requests
- React 18 + TypeScript — UI, MUI and MUI DataGrid, Tailwind, draw.io iFrame integration
- Vitest — unit, component and integration tests (the integration suite needs a real git binary)
- i18next — runtime i18n with EN/DE namespaces
- draw.io (diagrams.net) — embedded as iFrame for DFD editing
02
Feature Boundaries
Every feature is a full vertical slice — no feature may depend on another feature, not just the DFD/Threats pair. Anything needed across features lives in shared instead.
features/overview— project data, item / system definition, methodology view, source bindingsfeatures/hazards— hazard items, Bowtie, importfeatures/dfd— DFD modeling, draw.io bridge, graph builder, leveled DFDs, asset graphfeatures/assets— asset model, CIANAAA, impact criteriafeatures/threats— STRIDE generation (per element, per interaction), threat and mitigation catalogfeatures/attacktree— DSL, calculator, attack-path threat generatorfeatures/risks— risk register, likelihood methods, matrix, goals & claimsfeatures/compliance— requirement matrices (IEC 62443-4-2 editions, EN 50742 A)features/documentation— the generator engine covered in CLI Report Generatorfeatures/audit— git commit flow, signer manifest, Audit Verification Enginefeatures/integration— issue-tracker adaptersshared— all types and utilities used across features (DFDElementReference, StrideCategory, regulation presets, etc.)app— the composition layer: the workspace, cross-feature bridges (e.g. attack tree → risk likelihood) and schema migrations- Rule: no
features/*module may import from anotherfeatures/*module — only fromshared
03
Main process vs. Renderer process
Electron's two-process model maps directly onto two top-level folders:
Main process
electron/
Native OS integration, file I/O, keytar credential storage, IPC handlers — everything that needs Node/OS access.
Renderer process
src/
The React/TypeScript UI, feature modules, shared types — everything that runs in the Chromium window.