This release is 11 versions behind 1.1.4 — the latest version of @std/path. Jump to latest
Built and signed on GitHub ActionsBuilt and signed on GitHub Actions
Built and signed on GitHub Actions
Utilities for working with file system paths
Utilities for working with OS-specific file paths.
Functions from this module will automatically switch to support the path style
of the current OS, either windows for Microsoft Windows, or posix for
every other operating system, eg. Linux, MacOS, BSD etc.
To use functions for a specific path style regardless of the current OS import the modules from the platform sub directory instead.
Example, for POSIX:
import { fromFileUrl } from "@std/path/posix/from-file-url"; import { assertEquals } from "@std/assert"; assertEquals(fromFileUrl("file:///home/foo"), "/home/foo");
Or, for Windows:
import { fromFileUrl } from "@std/path/windows/from-file-url"; import { assertEquals } from "@std/assert"; assertEquals(fromFileUrl("file:///home/foo"), "\\home\\foo");
Functions for working with URLs can be found in @std/path/posix.
Built and signed on
GitHub Actions
Add Package
deno add jsr:@std/path
Import symbol
import * as path from "@std/path";
Import directly with a jsr specifier
import * as path from "jsr:@std/path";