Search results
26 packages found
insert implicit module globals into a module-deps stream
make ESM a bit more commonJS
ESM replacements for __dirname and __filename.
Access to __filename and __dirname within ECMAScript modules
Babel plugin that returns an object containing paths like __dirname and __filename as static values
- __dirname
- __filename
- babel
- babel-plugin-macros
- base
- extention
- file
- filename
- gitRoot
- npmRoot
- path
- paths
- plugin
- static
- View more
📍 '__dirname' and '__filename' in harmony modules
provides utilities for nodejs to be able to resolve es modules, such as providing the __dirname and __filename variables
A module to bring back `__dirname` and `__filename` within 2 lines of code.
insert implicit module globals into a module-deps stream
Polyfills for ESM like __dirname, __filename, etc
A tiny isomorphic ESM alternative to Node's __filename global.
This module, require-from-es, makes require, __dirname and __filename work flawlessly in ES-modules.
Fetch the current file and directory path, no matter your environment (Deno, Node.js, Web Browsers, ESM, CJS)
- __dirname
- __filename
- commonjs
- directory
- dirname
- ecmascript
- es2019
- esm
- export-default
- file
- filename
- import
- mjs
- modules
- View more
Babel plugin that returns an object containing paths like __dirname and __filename as static values
- __dirname
- __filename
- babel
- babel-plugin-macros
- base
- extention
- file
- filename
- gitRoot
- npmRoot
- path
- paths
- plugin
- static
- View more
You can use __dirname and __filename when using ESM
Alternatives to `__dirname` and `__filename` when using ES modules.
Easy __dirname and __filename alternatives for ES Modules
A micro helper for `import.meta` data
Babel plugin that rewrites __dirname and __filename to static values