Insert nodes before this node.

        If nodes contains ``str``, it will be converted to Text node.

def before(self, *nodes: Union[AbstractNode, str]) -> None:
        """Insert nodes before this node.

        If nodes contains ``str``, it will be converted to Text node.
        """
        if self.parentNode:
            node = _to_node_list(nodes)
            self.parentNode.insertBefore(node, self)