Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Protected blocks

Protected blocks allow you use separate attributes for an inner scope.

They behave differently than regular blocks in the following ways:

  1. They don't consume attributes.
  2. Attribute changes inside the block won't persist outside of the block.
  3. They do not expand into duplicates of a parent block element.

Syntax

Prefix a block with @ to protect it.

[rep: 3]
@{ A{B} }
{C}
# -> ABCCC

The protected block is still normalized internally, but it stays a single element from the parent's point of view.