summaryrefslogtreecommitdiff
path: root/ext/node/polyfills/_fs/_fs_dirent.ts
diff options
context:
space:
mode:
authorDivy Srivastava <dj.srivastava23@gmail.com>2024-06-19 12:51:01 +0530
committerGitHub <noreply@github.com>2024-06-19 12:51:01 +0530
commit209b2868131f43e1707fc706805a270a2b73d45a (patch)
tree21cc20106b54307be1627ffb2a413735554caa99 /ext/node/polyfills/_fs/_fs_dirent.ts
parent1d6b775f812f22f90d27a5d81a59070ad2d1172b (diff)
fix(ext/node): Add Dirent.path and Dirent.parentPath (#24257)
Diffstat (limited to 'ext/node/polyfills/_fs/_fs_dirent.ts')
-rw-r--r--ext/node/polyfills/_fs/_fs_dirent.ts9
1 files changed, 9 insertions, 0 deletions
diff --git a/ext/node/polyfills/_fs/_fs_dirent.ts b/ext/node/polyfills/_fs/_fs_dirent.ts
index 155d5cb03..0f80fc135 100644
--- a/ext/node/polyfills/_fs/_fs_dirent.ts
+++ b/ext/node/polyfills/_fs/_fs_dirent.ts
@@ -43,4 +43,13 @@ export default class Dirent {
get name(): string | null {
return this.entry.name;
}
+
+ get parentPath(): string {
+ return this.entry.parentPath;
+ }
+
+ /** @deprecated */
+ get path(): string {
+ return this.parentPath;
+ }
}