Skip to content

Commit

Permalink
refactor: replace path class with @david/path
Browse files Browse the repository at this point in the history
  • Loading branch information
dsherret committed Aug 27, 2024
1 parent 0c1cc7b commit 9a64652
Show file tree
Hide file tree
Showing 13 changed files with 189 additions and 2,472 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -612,7 +612,7 @@ pb.with(() => {

## Path API

The path API offers an immutable [`Path`](https://jsr.io/@david/dax/doc/~/Path) class, which is a similar concept to Rust's `PathBuf` struct.
The path API offers an immutable [`Path`](https://jsr.io/@david/path/doc/~/Path) class via [`jsr:@david/path`](https://jsr.io/@david/path), which is a similar concept to Rust's `PathBuf` struct.

```ts
// create a `Path`
Expand Down Expand Up @@ -659,7 +659,7 @@ const pathStringFileUrl = $.path("file:///tmp"); // converts to /tmp
const pathImportMeta = $.path(import.meta); // the path for the current module
```

There are a lot of helper methods here, so check the [documentation on Path](https://jsr.io/@david/dax/doc/~/Path) for more details.
There are a lot of helper methods here, so check the [documentation on Path](https://jsr.io/@david/path/doc/~/Path) for more details.

## Helper functions

Expand Down
18 changes: 9 additions & 9 deletions deno.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
{
"name": "@david/dax",
"version": "0.0.0",
"nodeModulesDir": false,
"tasks": {
"test": "deno test -A",
Expand Down Expand Up @@ -32,14 +31,15 @@
],
"exports": "./mod.ts",
"imports": {
"@deno/dnt": "jsr:@deno/dnt@^0.41.1",
"@std/assert": "jsr:@std/assert@^0.221.0",
"@std/fmt": "jsr:@std/fmt@^0.221.0",
"@std/fs": "jsr:@std/[email protected]",
"@std/io": "jsr:@std/[email protected]",
"@std/path": "jsr:@std/[email protected]",
"@std/streams": "jsr:@std/[email protected]",
"which": "jsr:@david/which@^0.4.1",
"@deno/dnt": "jsr:@deno/dnt@~0.41.3",
"@david/path": "jsr:@david/[email protected]",
"@std/assert": "jsr:@std/assert@1",
"@std/fmt": "jsr:@std/fmt@1",
"@std/fs": "jsr:@std/fs@1",
"@std/io": "jsr:@std/[email protected]",
"@std/path": "jsr:@std/path@1",
"@std/streams": "jsr:@std/[email protected]",
"which": "jsr:@david/which@~0.4.1",
"which_runtime": "jsr:@david/[email protected]"
}
}
Loading

0 comments on commit 9a64652

Please sign in to comment.