UNPKG

yaml-unist-parser

Version:

A YAML parser that produces output compatible with unist

10 lines (9 loc) 344 B
import { createLeadingCommentAttachable } from "./leading-comment-attachable.js"; import { createNode } from "./node.js"; export function createFlowMappingItem(position, key, value) { return { ...createNode("flowMappingItem", position), ...createLeadingCommentAttachable(), children: [key, value], }; }