updateNode method

void updateNode(
  1. Node node,
  2. Attributes attributes
)

Updates the attributes of the Node.

The attributes will be merged into the existing attributes.

Implementation

void updateNode(Node node, Attributes attributes) {
  final inverted = invertAttributes(node.attributes, attributes);
  add(
    UpdateOperation(
      node.path,
      {...attributes},
      inverted,
    ),
  );
}