diff --git a/doc/api/esm.md b/doc/api/esm.md index 4d257c37bf01ff..8ebcfe17ad0db4 100644 --- a/doc/api/esm.md +++ b/doc/api/esm.md @@ -384,6 +384,20 @@ import { readFileSync } from 'node:fs'; const buffer = readFileSync(new URL('./data.proto', import.meta.url)); ``` +### `import.meta.require(id)` + + + +> Stability: 1.1 - Active development + +* `id` {string} The module name or path. +* Returns: {any} The module exports. + +Alias for [`module.createRequire(import.meta.url)(specifier)`][]. + ### `import.meta.resolve(specifier)`