AtlatestRepositorysigil-doc

sigil-doc / tree / test / fixturespractical-author-support.sgl

1(define-library (fixtures practical-author-support)
2 (import (sigil core) (sigil doc author))
3 (export repeat-sections)
4 (begin
5 (define (repeat-sections label (keys: (count 1)))
6 (let loop ((i 1) (out '()))
7 (if (> i count) (reverse out)
8 (loop (+ i 1)
9 (cons (section (string-append label " " (number->string i))
10 id: (string-append "computed-section-" (number->string i))
11 (p (text "Computed by an imported ordinary Sigil function.")))
12 out)))))))