Skip to main content
Home
This release is 8 versions behind 1.3.4 — the latest version of @reliverse/pathkit. Jump to latest

@reliverse/pathkit is a slash‑consistent, cross‑platform path manipulation, with POSIX forward slash, drop‑in for node:path and unjs/pathe. This library extends the node:path module with a set of functions for manipulating file paths.

This package works with Node.js, BunIt is unknown whether this package works with Cloudflare Workers, Deno, Browsers
It is unknown whether this package works with Cloudflare Workers
This package works with Node.js
It is unknown whether this package works with Deno
This package works with Bun
It is unknown whether this package works with Browsers
JSR Score
94%
Published
2 weeks ago (1.2.6)
f
attachPathSegments

attaches path segments to an existing path

f
attachPathSegmentsInDirectory

recursively processes files in a directory to attach path segments to import statements

f
basename

gets base filename from path

f
convertImportsAliasToRelative

main function to convert import paths from aliases to relative paths

f
convertImportsExt

converts extensions in import paths from one format to another

f
convertStringAliasRelative

converts aliased path to relative path

v
default
No documentation available
v
delimiter
No documentation available
f
dirname

gets directory name from path

f
extname

gets file extension including the dot

f
filename

gets filename without extension

f
format

formats object parts into a path string

I
FormatInputPathObject
No documentation available
f
getFileImportsExports

analyzes a file's content to extract import and export statements

I
ImportExportSpecifier
No documentation available
T
ImportExtType
No documentation available
f
isAbsolute

checks if path is absolute

f
join

joins path segments with proper normalization

f
normalize

normalizes a path, resolving . and .. segments

f
normalizeAliases

normalizes alias records and optimizes nested aliases

f
normalizeWindowsPath

normalizes windows paths to use forward slashes

f
parse

parses a path into its components

I
ParsedPath
No documentation available
T
PathExtFilter
No documentation available
f
relative

gets relative path from one path to another

f
resolve

resolves path to an absolute path

f
resolveAlias

resolves a path using aliases

f
reverseResolveAlias

finds all alias paths that could resolve to the given path

v
sep
No documentation available
f
stripPathSegments

strips a specified number of segments from the beginning of a path

f
stripPathSegmentsInDirectory

recursively processes files in a directory to strip path segments from their contents

f
toNamespacedPath

converts path to namespaced path for windows

v
win32
No documentation available

New Ticket: Report package

Please provide a reason for reporting this package. We will review your report and take appropriate action.

Please review the JSR usage policy before submitting a report.