Skip to content

Commit c9e96da

Browse files
committed
feat: add lstat
1 parent 133d602 commit c9e96da

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/index.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,11 @@ export const stat = quansync({
9595
> &
9696
QuansyncFn<Stats | BigIntStats, [path: PathLike, opts?: StatOptions]>
9797

98+
export const lstat = quansync({
99+
sync: (path: PathLike, options) => fs.lstatSync(path, options),
100+
async: (path, options) => fs.promises.lstat(path, options),
101+
}) as typeof stat
102+
98103
/**
99104
* @link https://nodejs.org/api/fs.html#fspromisescpsrc-dest-options
100105
*/

0 commit comments

Comments
 (0)