aboutsummaryrefslogtreecommitdiff
path: root/src/bun.js/path-posix.exports.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/bun.js/path-posix.exports.js')
-rw-r--r--src/bun.js/path-posix.exports.js35
1 files changed, 35 insertions, 0 deletions
diff --git a/src/bun.js/path-posix.exports.js b/src/bun.js/path-posix.exports.js
new file mode 100644
index 000000000..b3f61c1a2
--- /dev/null
+++ b/src/bun.js/path-posix.exports.js
@@ -0,0 +1,35 @@
+function bound(obj) {
+ return {
+ basename: obj.basename.bind(obj),
+ dirname: obj.dirname.bind(obj),
+ extname: obj.extname.bind(obj),
+ format: obj.format.bind(obj),
+ isAbsolute: obj.isAbsolute.bind(obj),
+ join: obj.join.bind(obj),
+ normalize: obj.normalize.bind(obj),
+ parse: obj.parse.bind(obj),
+ relative: obj.relative.bind(obj),
+ resolve: obj.resolve.bind(obj),
+ toNamespacedPath: obj.toNamespacedPath.bind(obj),
+ sep: obj.sep,
+ delimiter: obj.delimiter,
+ };
+}
+var path = bound(Bun._Path(false));
+
+export var {
+ basename,
+ dirname,
+ extname,
+ format,
+ isAbsolute,
+ join,
+ normalize,
+ parse,
+ relative,
+ resolve,
+ toNamespacedPath,
+ sep,
+ delimiter,
+} = path;
+export default path;