MCPcopy Index your code
hub / github.com/nodejs/node / require-cjs.mjs

File require-cjs.mjs

test/fixtures/es-modules/require-cjs.mjs:None–None  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1import { createRequire } from "node:module";
2const require = createRequire(import.meta.url);
3const exports = require('./required-cjs');
4console.log(exports.hello);

Callers

nothing calls this directly

Calls 3

createRequireFunction · 0.85
requireFunction · 0.70
logMethod · 0.45

Tested by

no test coverage detected