@@ -235,7 +235,7 @@ the `require.resolve()` function.
235235Putting together all of the above, here is the high-level algorithm
236236in pseudocode of what ` require() ` does:
237237
238- < pre >
238+ ``` pre html
239239require(X) from module at path Y
2402401. If X is a core module,
241241 a. return the core module
@@ -256,7 +256,7 @@ MAYBE_DETECT_AND_LOAD(X)
2562561. If X parses as a CommonJS module, load X as a CommonJS module. STOP.
2572572. Else, if `--experimental-require-module` and `--experimental-detect-module` are
258258 enabled, and the source code of X can be parsed as ECMAScript module using
259- <a href =" esm.md#resolver -algorithm-specification " >DETECT_MODULE_SYNTAX defined in
259+ <a href="esm.md#resolution -algorithm-specification">DETECT_MODULE_SYNTAX defined in
260260 the ESM resolver</a>,
261261 a. Load X as an ECMAScript module. STOP.
2622623. THROW the SyntaxError from attempting to parse X as CommonJS in 1. STOP.
@@ -318,7 +318,7 @@ LOAD_PACKAGE_IMPORTS(X, DIR)
3183182. If no scope was found, return.
3193193. If the SCOPE/package.json "imports" is null or undefined, return.
3203204. let MATCH = PACKAGE_IMPORTS_RESOLVE(X, pathToFileURL(SCOPE),
321- ["node", "require"]) <a href =" esm.md#resolver -algorithm-specification " >defined in the ESM resolver</a >.
321+ ["node", "require"]) <a href="esm.md#resolution -algorithm-specification">defined in the ESM resolver</a>.
3223225. RESOLVE_ESM_MATCH(MATCH).
323323
324324LOAD_PACKAGE_EXPORTS(X, DIR)
@@ -329,7 +329,7 @@ LOAD_PACKAGE_EXPORTS(X, DIR)
3293293. Parse DIR/NAME/package.json, and look for "exports" field.
3303304. If "exports" is null or undefined, return.
3313315. let MATCH = PACKAGE_EXPORTS_RESOLVE(pathToFileURL(DIR/NAME), "." + SUBPATH,
332- `package.json` "exports", ["node", "require"]) <a href =" esm.md#resolver -algorithm-specification " >defined in the ESM resolver</a >.
332+ `package.json` "exports", ["node", "require"]) <a href="esm.md#resolution -algorithm-specification">defined in the ESM resolver</a>.
3333336. RESOLVE_ESM_MATCH(MATCH)
334334
335335LOAD_PACKAGE_SELF(X, DIR)
@@ -339,15 +339,15 @@ LOAD_PACKAGE_SELF(X, DIR)
3393394. If the SCOPE/package.json "name" is not the first segment of X, return.
3403405. let MATCH = PACKAGE_EXPORTS_RESOLVE(pathToFileURL(SCOPE),
341341 "." + X.slice("name".length), `package.json` "exports", ["node", "require"])
342- <a href =" esm.md#resolver -algorithm-specification " >defined in the ESM resolver</a >.
342+ <a href="esm.md#resolution -algorithm-specification">defined in the ESM resolver</a>.
3433436. RESOLVE_ESM_MATCH(MATCH)
344344
345345RESOLVE_ESM_MATCH(MATCH)
3463461. let RESOLVED_PATH = fileURLToPath(MATCH)
3473472. If the file at RESOLVED_PATH exists, load RESOLVED_PATH as its extension
348348 format. STOP
3493493. THROW "not found"
350- </ pre >
350+ ```
351351
352352## Caching
353353
0 commit comments