Current offset since the start of parsing
Top indicates the node that's currently being built
Parse source as a YAML stream.
If incomplete, a part of the last line may be left as a buffer for the next call.
Errors are not thrown, but yielded as { type: 'error', message } tokens.
Optionalincomplete: booleanA generator of tokens representing each directive, document, and other structure.
A YAML concrete syntax tree (CST) parser
To use the parser with a user-provided lexer: