Extending the workbook
To add another chapter:
- Create the next
phaseN/folder. - Write
phaseN/allowed.mdbefore creating examples. - Add focused lesson pages to that phase.
- Create
book/NN-phaseN.htmlusing an existing chapter page as the structural template. - Include learning goals, new concepts, lesson links, a comparison with the previous phase, and a checkpoint.
- Add the chapter to
../index.html. - Update the previous chapter’s Next link and the new chapter’s Previous link.
- If inserting a chapter, renumber later book filenames, visible chapter numbers, and previous/next links together; phase folder names do not need to match book chapter numbers.
- Leave most completed phase exercises unchanged so the learning history remains visible; update representative pages when a foundational concept should be reinforced later.
Named lab folders can also be promoted into the main sequence. Keep the descriptive folder name, give it a numbered chapter page, update adjacent chapter links, and make its allowed.md gauge state exactly which phase it inherits. The promoted flexbox/ chapter is the working example.
Refreshing readable documentation
After editing rules.md, an allowed.md, or another rendered guide, run:
python3 book/render_docs.py
This updates the styled HTML copies in book/docs/. Markdown remains the editable source.
Use relative links:
- From a book chapter to an exercise:
../phaseN/01-lesson.html - From a book chapter to the book contents:
../index.html - Between book chapters:
./NN-chapter.html