diff --git a/gulpfile.mjs b/gulpfile.mjs index bf589fbc39d4d..405374f6886da 100644 --- a/gulpfile.mjs +++ b/gulpfile.mjs @@ -68,7 +68,7 @@ const TMP_DIR = BUILD_DIR + "tmp/"; const TYPESTEST_DIR = BUILD_DIR + "typestest/"; const COMMON_WEB_FILES = [ "web/images/*.{png,svg,gif}", - "web/debugger.{css,js}", + "web/debugger.{css,mjs}", ]; const MOZCENTRAL_DIFF_FILE = "mozcentral.diff"; diff --git a/web/debugger.js b/web/debugger.mjs similarity index 99% rename from web/debugger.js rename to web/debugger.mjs index 9160f840f1dd4..9fe79d8c120ed 100644 --- a/web/debugger.js +++ b/web/debugger.mjs @@ -574,7 +574,7 @@ class PDFBug { const link = document.createElement("link"); link.rel = "stylesheet"; - link.href = url.replace(/.js$/, ".css"); + link.href = url.replace(/\.mjs$/, ".css"); document.head.append(link); } diff --git a/web/viewer.js b/web/viewer.js index bfe7b3e876c5f..3e2947f0fcf51 100644 --- a/web/viewer.js +++ b/web/viewer.js @@ -178,7 +178,7 @@ function getViewerConfiguration() { typeof PDFJSDev === "undefined" || PDFJSDev.test("GENERIC") ? document.getElementById("fileInput") : null, - debuggerScriptPath: "./debugger.js", + debuggerScriptPath: "./debugger.mjs", }; }