From afd1f91a1e26539b66ecdb36014d701328f0ff67 Mon Sep 17 00:00:00 2001 From: pacexy Date: Wed, 15 Jan 2025 18:25:46 +0800 Subject: [PATCH] module: fix jsdoc for `format` parameter in cjs/loader PR-URL: https://github.com/nodejs/node/pull/56501 Reviewed-By: James M Snell Reviewed-By: Jason Zhang Reviewed-By: Qingyu Deng --- lib/internal/modules/cjs/loader.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lib/internal/modules/cjs/loader.js b/lib/internal/modules/cjs/loader.js index c453f2b403e89d..0bc421e172303b 100644 --- a/lib/internal/modules/cjs/loader.js +++ b/lib/internal/modules/cjs/loader.js @@ -1682,9 +1682,8 @@ function wrapSafe(filename, content, cjsModuleInstance, format) { * `exports`) to the file. Returns exception, if any. * @param {string} content The source code of the module * @param {string} filename The file path of the module - * @param { - * 'module'|'commonjs'|'commonjs-typescript'|'module-typescript' - * } format Intended format of the module. + * @param {'module'|'commonjs'|'commonjs-typescript'|'module-typescript'|'typescript'} format + * Intended format of the module. */ Module.prototype._compile = function(content, filename, format) { if (format === 'commonjs-typescript' || format === 'module-typescript' || format === 'typescript') {