esm: fix jsdoc type refs to `ModuleJobBase` in esm/loader · nodejs/node@c85b386

@@ -43,6 +43,8 @@ const {

4343

let defaultResolve, defaultLoad, defaultLoadSync, importMetaInitializer;

44444545

/**

46+

* @typedef {import('./hooks.js').HooksProxy} HooksProxy

47+

* @typedef {import('./module_job.js').ModuleJobBase} ModuleJobBase

4648

* @typedef {import('url').URL} URL

4749

*/

4850

@@ -138,6 +140,7 @@ class ModuleLoader {

138140

* to this property and failure to do so will cause undefined

139141

* behavior when invoking `import.meta.resolve`.

140142

* @see {ModuleLoader.setCustomizations}

143+

* @type {CustomizedModuleLoader}

141144

*/

142145

#customizations;

143146

@@ -194,7 +197,7 @@ class ModuleLoader {

194197

*

195198

* Calling this function alters how modules are loaded and should be

196199

* invoked with care.

197-

* @param {object} customizations

200+

* @param {CustomizedModuleLoader} customizations

198201

*/

199202

setCustomizations(customizations) {

200203

this.#customizations = customizations;

@@ -227,7 +230,7 @@ class ModuleLoader {

227230

* @param {string} [parentURL] The URL of the module where the module request is initiated.

228231

* It's undefined if it's from the root module.

229232

* @param {ImportAttributes} importAttributes Attributes from the import statement or expression.

230-

* @returns {Promise<ModuleJobBase}

233+

* @returns {Promise<ModuleJobBase>}

231234

*/

232235

async getModuleJobForImport(specifier, parentURL, importAttributes) {

233236

const resolveResult = await this.resolve(specifier, parentURL, importAttributes);

@@ -241,7 +244,7 @@ class ModuleLoader {

241244

* @param {string} specifier See {@link getModuleJobForImport}

242245

* @param {string} [parentURL] See {@link getModuleJobForImport}

243246

* @param {ImportAttributes} importAttributes See {@link getModuleJobForImport}

244-

* @returns {Promise<ModuleJobBase}

247+

* @returns {Promise<ModuleJobBase>}

245248

*/

246249

getModuleJobForRequireInImportedCJS(specifier, parentURL, importAttributes) {

247250

const resolveResult = this.resolveSync(specifier, parentURL, importAttributes);

@@ -607,7 +610,7 @@ class ModuleLoader {

607610

/**

608611

* Similar to {@link resolve}, but the results are always synchronously returned. If there are any

609612

* asynchronous resolve hooks from module.register(), it will block until the results are returned

610-

* from the loader thread for this to be synchornous.

613+

* from the loader thread for this to be synchronous.

611614

* This is here to support `import.meta.resolve()`, `require()` in imported CJS, and

612615

* future synchronous hooks.

613616

*