You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
(fix) use console.log for .js.js deprecation warning
Technically (with a build system) this code could end up in the
browser, so we should use only APIs available in both browser and
node.js.
Resolves#3222.
Copy file name to clipboardExpand all lines: tools/build_node.js
+2-3Lines changed: 2 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -34,9 +34,8 @@ async function buildNodeLanguage(language, options) {
34
34
constEMIT=`function emitWarning() {
35
35
if (!emitWarning.warned) {
36
36
emitWarning.warned = true;
37
-
process.emitWarning(
38
-
'Using file extension in specifier is deprecated, use "highlight.js/lib/languages/%%%%" instead of "highlight.js/lib/languages/%%%%.js"',
39
-
'DeprecationWarning'
37
+
console.log(
38
+
'Deprecation (warning): Using file extension in specifier is deprecated, use "highlight.js/lib/languages/%%%%" instead of "highlight.js/lib/languages/%%%%.js"'
0 commit comments