MCPcopy
hub / github.com/webpack/webpack / toNormalComment

Method toNormalComment

lib/Template.js:143–146  ·  view source on GitHub ↗

* Returns a commented version of string. * @param {string} str string to be converted to "normal comment" * @returns {string} returns a commented version of string

(str)

Source from the content-addressed store, hash-verified

141 * @returns {string} returns a commented version of string
142 */
143 static toNormalComment(str) {
144 if (!str) return "";
145 return `/* ${str.includes("*/") ? str.replace(COMMENT_END_REGEX, "* /") : str} */`;
146 }
147
148 /**
149 * Returns normalized bundle-safe path.

Callers 15

commentMethod · 0.80
weakErrorMethod · 0.80
exportFromImportMethod · 0.80
renderRuntimeModulesMethod · 0.80
getFinalBindingFunction · 0.80
codeGenerationMethod · 0.80
_addExportFragmentsMethod · 0.80
getReturnValueMethod · 0.80
applyMethod · 0.80

Calls 1

replaceMethod · 0.45

Tested by

no test coverage detected