A TypeScript CLI that converts a YAML-formatted CV into a styled PDF.
- Node.js 18+
- npm
npm install# reads cv.yaml → output/resume.pdf
npm start
# custom input/output paths
npm start -- --input my.yaml --output out.pdfsrc/
index.ts — CLI entry point, parses --input / --output args
parser.ts — reads YAML file, returns typed CV object (js-yaml)
types.ts — TypeScript interfaces mirroring the YAML schema
renderer.ts — all pdfkit drawing logic (header, sections, layout)
cv.yaml — your CV data
cv.example.yaml — full schema example with placeholder data
output/ — generated PDFs land here (git-ignored)
See cv.example.yaml for a complete example. The structure:
cv:
name: "Jane Doe"
headline: "Your title / tagline"
location: "City, Country"
email: "you@example.com"
phone: "+1 234 567 8900"
social_networks:
- network: LinkedIn # LinkedIn | GitHub | Telegram
username: "jane-doe"
sections:
summary:
- "A paragraph of text describing your background."
experience:
- company: "Acme Corp"
position: "Software Engineer"
start_date: "2024-01" # YYYY-MM
end_date: "present" # YYYY-MM or "present"
location: "City (Remote)"
highlights:
- "Accomplishment or responsibility."
education:
- institution: "University Name"
area: "Field of Study"
degree: "Degree Title"
start_date: "2018-09"
end_date: "2022-07"
skills:
- label: "Frontend"
details: "React, TypeScript, Next.js"| Package | Purpose |
|---|---|
pdfkit |
PDF generation (A4, Helvetica, manual layout) |
js-yaml |
YAML parsing |
ts-node |
Run TypeScript without a build step |
typescript |
Type checking |