How can I get different headers per chapter?

I would like to have a text line in the header of the pages that is different for each chapter. The first page of a chapter should not have a header.

What you want is probably this package:

Interesting package! I’ll keep that in mind. Thank you.

But it doesn’t provide the functionality I want. The line of text I want to display in the header area should be independent of the header.

1 Like

I have found out. It’s much easier than I thought:

= Chap 1

#set page(header: [Some text in the heder of Chap 1])

#lorem(30)

= Chap 2

#set page(header: [Some text in the heder of Chap 2])

#lorem(30)

= Chap 3

#set page(header: none)

#lorem(30)