I use this gulp flow to generate my resume in PDF and HTML format from the same source files, mostly in markdown and also a tiny bit of pug templating.
This flow will generate a private and a public resume, where the public version contains crawler-sensitive data like my email and phone number spelled out to try to avoid crawlers and spam.
The output HTML files are self-contained as they have all the needed styles and fonts inline.
npm install
npx gulp serve: Will start a local server with a preview of the resume. The files will be served formpublic/. Useful to preview your changes in real time. Keep in mind the PDF rendering will also use theprint.lessfile.npx gulp pdf: Will rungulp build:inlineand create the PDF file in the same directorynpx gulp build: Will generate all the files needed to upload your resume to a web server, under thedist/
Check gulpfile.js for additional commands.
src/index.html: HTML structuresrc/styles/main.less: Main LESS stylessrc/styles/print.less: Print styles which will be used to generate the PDF