Skip to content

PurePath.asURI() method

pathlib-ts > PurePath > asURI

Converts the path to a file:// URI string.

Signature:

asURI(): string;

Returns:

string

RFC 8089 compliant file URI.

The Error class If the path is relative.

The path must be absolute. The output is suitable for environments that consume RFC 8089 URIs.