document method

Parser<DocumentNode> document()
inherited

The root document consisting of zero or more blocks.

Implementation

Parser<DocumentNode> document() =>
    seq4(
      position(),
      ref0(blockItem).star(),
      ref0(blankLine).star(),
      position(),
    ).map4(
      (start, blocks, _, stop) =>
          DocumentNode(blocks, start: start, stop: stop),
    );