跳到主要内容

handout-only

handout-only(body)(source)

Display content only in handout mode. (not presentation) Don't reserve space when hidden, content is completely not existing there.

Unlike handout-only/presentation-only's old callback-based implementation, body here is embedded directly (not wrapped in a deferred touying-fn-wrapper call) — self.handout is a static, per-compile value, so which mode is active can be decided once at slide-splitting time. This is also what lets body contain its own slide-breaking elements (a heading, #pagebreak(), ---) and have them behave exactly as if this wrapper weren't there, in whichever mode this content is actually visible.

Example:

#handout-only[This content is only visible in handout mode.]
Parameters

body : content​

The content to display in handout mode.

Returns: content