docs: def to_bel(graph, file: Optional[TextIO] = None) -> None:
      """Output the BEL graph as canonical BEL to the given file/file-like/stream.
  
      :param BELGraph graph: the BEL Graph to output as a BEL Script
      :param file: A writable file-like object. If None, defaults to standard out.
      """
      for line in to_bel_lines(graph):
          print(line, file=file)