mirror of
https://github.com/denoland/deno.git
synced 2024-12-15 11:58:42 -05:00
dfc5eec43c
This commit adds support for executing top-level `.cjs` files, as well as import `.cjs` files from within npm packages. This works only for `.cjs` files, the contents of sibling `package.json` are not consulted for the `"type"` field. Closes https://github.com/denoland/deno/issues/25384 --------- Signed-off-by: David Sherret <dsherret@users.noreply.github.com> Co-authored-by: Luca Casonato <hello@lcas.dev> Co-authored-by: David Sherret <dsherret@users.noreply.github.com>
9 lines
154 B
JavaScript
9 lines
154 B
JavaScript
const process = require("process");
|
|
const a = require("./a");
|
|
|
|
console.log(process.cwd());
|
|
|
|
module.exports = {
|
|
cwd: process.cwd,
|
|
foobar: a.foobar,
|
|
};
|