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

API Reference

deixis-update-note-counter

Sets a stream to an integer or applies current → integer. The next numbered original increments that value.

Setup Required

Returns: content.

Task guide

Example

deixis-update-note-counter(0)

Unnumbered originals, bodies, references and reuse never increment. Earlier notes keep assigned numbers. Endnote wrappers use the “endnote” series; select it explicitly for their resets.

deixis-update-note-counter

deixis-update-note-counter(value, target: 0, series: "default")

Set or update the current counter value for one target scope and series. The next numbered original mark increments that value. Resetting to zero makes the next numbered original use one; earlier notes retain their assigned numbers and identities. Unnumbered originals, bodies, references, and reused marks do not increment it.

Reset a stream at a chapter or section boundary, or use deixis-block for an independent local collection. Other series are unaffected.

  • value (int, function): Integer or a function (current) => int. Direct values and results must be integers; strings, floats, and booleans are not coerced. Negative displayed counts need a suitable numbering callback.
  • target (int, label, str): Current scope (0), ancestor (negative integer), named/forward scope, or global "page". Updates affect all scopes synchronized with that counter owner.
  • series (str): Literal series name, default "default"; other series are untouched.
//| sandbox-mode: "page"
#deixis-update-note-counter(0)
#context deixis-note-counter()

Parameters

NameDefaultTypes
valuerequiredint, function
target0int, label, str
series"default"str

value

Integer or a function of the current value returning an integer. Use 0 to restart the next numbered original at 1. Values are not coerced.

target

Current scope (0), ancestor (negative integer), named/forward scope, or “page”.

series

The specific note series to update.