Repository navigation
Lima 0.8.0 — outline() for editors
Lima 0.8.0 adds outline() to the JavaScript package: where each key, comment and error of a document stands in the source, for editors.
Added
- JavaScript:
outline(input). Returns every key with its decoded name, its path, the span of the key as written and of its separator, every comment, and what a strictparsewould report. Spans have a line, a column and an offset in UTF-16 code units, the shapes the Markanto parser uses. It reads with the parser's own readers, soAutor:in: xhas the keyAutor:inand the lines of a|scalar are no keys; it never throws for content, and a half-typed line leaves the keys below it in place. The first user is the block editor of hadley, which shows front matter as a striped table.
Rust and Go are unchanged; their version follows the repository's.
parse, parseCore and parseReferences are unchanged; benchmarks show no regression.