Skip to content

Commit 0269243

Browse files
authored
Adds a loader for manifest loading
1 parent 8cd4be3 commit 0269243

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

doc/design/overview.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@ There are currently [three loader hooks](https://github.com/nodejs/node/tree/mas
44

55
1. `resolve`: Takes a specifier (the string after `from` in an `import` statement) and converts it into an URL to be loaded.
66

7+
1. `loadManifest`: Takes the resolved URL and returns the `package.json` from the location (or `null` if it doesn't exist).
8+
79
1. `load`: Takes the resolved URL and returns runnable code (JavaScript, Wasm, etc.) as well as the name of one of Node’s ESM loader’s [“translators”](https://github.com/nodejs/node/blob/master/lib/internal/modules/esm/translators.js):
810
* `commonjs`
911
* `module`

0 commit comments

Comments
 (0)