Skip to main content

display-current-heading

Display the current heading on the page.

Parameters

level : int | auto    default: auto​

The level of the heading. If level is auto, it will return the last heading on or before the current page. If level is a number, it will return the last heading on or before the current page with the same level.

numbered : bool​

Whether to display the heading numbering. Default is true.

hierachical : bool    default: true​

Whether to return the heading hierarchically. If true, returns the last heading according to the hierarchical structure. If false, returns the last heading on or before the current page with the same level.

depth : int    default: 9999​

The maximum depth of the heading to search. Usually, it should be set as slide-level.

setting : function​

The setting of the heading. Default is body => body.

style : function​

The style of the heading. If style is a function, it will use the function to style the heading. For example, style: current-heading => current-heading.body. If you set it to style: auto, it will be controlled by show heading rules.

Returns: content