Skip to main content
Log in

Mojo function

split_extension

split_extension[PathLike: PathLike, //](path: PathLike) -> Tuple[String, String]

Splits path into the root and extension.

Parameters:

  • PathLike (PathLike): The type conforming to the os.PathLike trait.

Args:

  • path (PathLike): The path to be split.

Returns:

A tuple containing two strings: (root, extension).