Search results

32 packages found

insert implicit module globals into a module-deps stream

published version 7.2.1, 5 years ago56 dependents licensed under $MIT
4,404,702

Access to __filename and __dirname within ECMAScript modules

published version 1.1.2, 8 months ago11 dependents licensed under $MIT
477,245

Fetch the current file and directory path, no matter your environment (Deno, Node.js, Web Browsers, ESM, CJS)

published version 3.4.0, a year ago17 dependents licensed under $Artistic-2.0
29,887

Babel plugin that returns an object containing paths like __dirname and __filename as static values

published version 3.0.1, 5 years ago6 dependents licensed under $MIT
38,319

Easy __dirname and __filename alternatives for ES Modules

published version 1.1.2, 9 months ago128 dependents licensed under $MIT
23,862

provides utilities for nodejs to be able to resolve es modules, such as providing the __dirname and __filename variables

published version 1.0.1, 2 years ago4 dependents licensed under $ISC
10,922

Babel plugin that rewrites __dirname and __filename to static values

published version 1.1.0, 9 years ago6 dependents licensed under $MIT
9,019

Converts module differences in source files between ES and CommonJS.

published version 1.0.0-alpha.7, 7 days ago1 dependents licensed under $MIT
1,961

Polyfills for ESM like __dirname, __filename, etc

published version 1.0.1, 2 years ago1 dependents licensed under $MIT
849

Babel plugin that generates the namespace for creating a logger based on the path of the module

published version 0.4.1, 4 months ago0 dependents licensed under $MIT
450

[![CI](https://github.com/zirkelc/commonjs-shim/actions/workflows/ci.yml/badge.svg)](https://github.com/zirkelc/commonjs-shim/actions/workflows/ci.yml) [![npm](https://img.shields.io/npm/dt/commonjs-shim?label=commonjs-shim)](https://www.npmjs.com/package

published version 1.1.0, 15 days ago0 dependents licensed under $MIT
270

ESM replacements for __dirname and __filename.

published version 0.1.7, 2 years ago2 dependents licensed under $WTFPL
212

Alternatives to `__dirname` and `__filename` when using ES modules.

published version 1.1.1, 3 years ago0 dependents licensed under $MIT
154

make ESM a bit more commonJS

published version 1.0.1, 2 years ago0 dependents licensed under $MIT
184

You can use __dirname and __filename when using ESM

published version 1.0.15, 4 years ago1 dependents licensed under $MIT
46

A micro helper for `import.meta` data

published version 0.2.4, 5 years ago5 dependents licensed under $ISC
51

A require like function for GJS

published version 0.3.0, 6 years ago0 dependents licensed under $ISC
32

Handy function to handle import.meta

published version 0.1.0, 7 years ago0 dependents licensed under $MIT
24

Babel plugin that returns an object containing paths like __dirname and __filename as static values

published version 1.0.0, 7 years ago0 dependents licensed under $MIT
13

📍 '__dirname' and '__filename' in harmony modules

published version 1.1.0, 6 years ago0 dependents licensed under $MIT
14