Check PC build viability: chipset compatibility, minimum PSU recommendation and full TDP analysis — available as a web app and a terminal CLI.
🌐 Open the Web App | ⌨️ Run in terminal
- Card-based component selection — pick CPU and GPU from preset cards or enter custom specs
- Live TDP bar — sticky header shows total power draw as you select components
- Chipset compatibility — compatible chipsets highlight automatically after CPU selection
- PSU recommendation — picks the smallest standard commercial PSU that fits (with 30% safety margin)
- Shareable builds — results are encoded in the URL so you can share any build with a single link
- Copy results — export the analysis as plain text
- Mobile-friendly — responsive layout, works on phones and tablets
- Terminal CLI — full interactive interface for developers using Node.js + TypeScript
The index.html at the root is a self-contained single file — no build step, no server required.
Visit https://caiquecrepaldi.github.io/HardwareViabilidade/
# Just open the file — no server needed
start index.html # Windows
open index.html # macOS
xdg-open index.html # Linux- Go to your repository → Settings → Pages
- Under Source, choose Deploy from a branch
- Select branch
mainand folder/ (root) - Save — GitHub Pages will publish the site in ~1 minute
Full interactive terminal interface built with TypeScript + readline.
- Node.js 18 or higher
- npm
npm installnpm run devnpm run build:start══════════════════════════════════════════════════════════════
💻 HARDWARE VIABILITY CALCULATOR
══════════════════════════════════════════════════════════════
SELECT PROCESSOR (CPU)
──────────────────────────────────────────────────────────────
[1] Intel Core i9-14900K 125W Socket: LGA1700
[2] Intel Core i7-14700K 125W Socket: LGA1700
...
RELATÓRIO DE VIABILIDADE DE HARDWARE
══════════════════════════════════════════════════════════════
Processor: Intel Core i9-14900K
Graphics card: NVIDIA GeForce RTX 4090
POWER CONSUMPTION
Total TDP: 625 W
Minimum with 30% margin: 813 W
RECOMMENDED PSU: 850 W
PSU usage: [█████████████████████░░░░░░░░░░░] 74%
Status: ✓ COMPATIBLE
HardwareViabilidade/
├── index.html ← Web app (self-contained, GitHub Pages ready)
├── src/
│ ├── Componente.ts ← Abstract base class (inheritance)
│ ├── Processador.ts ← CPU subclass (extends Componente)
│ ├── PlacaVideo.ts ← GPU subclass (extends Componente)
│ ├── CalculadoraViabilidade.ts ← Business logic and constants
│ ├── banco-de-dados.ts ← Pre-registered CPUs and GPUs
│ └── main.ts ← Terminal interface (readline)
├── tsconfig.json
├── package.json
└── README.md
| Constant | Value | Description |
|---|---|---|
MARGEM_SEGURANCA |
30% | Safety margin added on top of total TDP |
OVERHEAD_SISTEMA_W |
50 W | Estimated power for RAM, SSDs, cooling, motherboard |
FONTES_PADRAO |
400–1500 W | Standard commercial PSU wattages |
Minimum PSU formula:
min_psu = (TDP_CPU + TDP_GPU + 50W) × 1.30
The recommended PSU is the smallest standard wattage (400, 450, 500 … 1500) that exceeds the minimum.
| Concept | Where applied |
|---|---|
| Abstract class | Componente — cannot be instantiated directly |
| Inheritance | Processador and PlacaVideo extend Componente |
readonly / constants |
TDPs, chipsets, and business constants are immutable |
abstract method |
descricao() enforced in subclasses |
interface |
ResultadoViabilidade types the analysis return object |
| Generics / types | Record<string, Processador> in the database |
strict: true |
Strict type-checking in tsconfig.json |
async/await |
Async I/O with readline |
| Error handling | try/catch with typed messages |
- Fork the repository
- Create a feature branch:
git checkout -b feature/my-feature - Commit your changes:
git commit -m 'add my feature' - Push:
git push origin feature/my-feature - Open a Pull Request
MIT — see LICENSE for details.