polars.DataFrame.to_json

DataFrame.to_json(file: Optional[Union[io.IOBase, str, pathlib.Path]] = None, pretty: bool = False, row_oriented: bool = False, json_lines: bool = False, *, to_string: Literal[True]) str
DataFrame.to_json(file: Optional[Union[io.IOBase, str, pathlib.Path]] = None, pretty: bool = False, row_oriented: bool = False, json_lines: bool = False, *, to_string: Literal[False] = False) None
DataFrame.to_json(file: Optional[Union[io.IOBase, str, pathlib.Path]] = None, pretty: bool = False, row_oriented: bool = False, json_lines: bool = False, *, to_string: bool = False) Optional[str]

Deprecated since version 0.13.12: Please use write_json