How can I create a fancy chapter title style in Typst (similar to LaTeX)

Thanks for sharing, but I couldn’t find the ones whose sole purpose is to style those headings. I would expect that to be named something along the lines of fncychap. Turns out that’s the exact package name in LaTeX.

Using show rules inside that scope is indeed useful. If you added more indentation spaces and put every argument on a new line, then the amount of code is still comparable to having no show rules. I guess the difference is more apparent with more repetitive code.

Referring to the code you highlighted on that GitHub link of yours, the answers here should also all use show heading.where(level: 1): ... since only the level one headings are intended to appear like that.

1 Like