Skip to main content
Works with
This package works with Node.js, Deno, Bun
This package works with Node.js
This package works with Deno
This package works with Bun
JSR Score100%
License
MIT
Downloads5,364/wk
Published2 months ago (0.3.3)

Path class for JavaScript built on top of Deno's standard library.

@david/path

JSR

Path class for JavaScript.

Setup

deno add @david/path

Example

import { path } from "@david/path";

const srcDir = path("src");

console.log(srcDir.existsSync());

const dataFile = srcDir.join("data.txt");
dataFile.writeTextSync("Hello there!");

Alternatively you can construct the Path class directly:

import { Path } from "@david/path";

const srcDir = new Path("src");

Road to 1.0

I would like to stabilize this, but first I want to get more feedback on it.

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.

Add Package

deno add jsr:@david/path

Import symbol

import * as path from "@david/path";
or

Import directly with a jsr specifier

import * as path from "jsr:@david/path@^0.3.3";