From b422e068c138b24ab2b82b71ac0550d5d88589c4 Mon Sep 17 00:00:00 2001 From: Chris Roos Date: Mon, 13 Jan 2025 12:35:13 +0000 Subject: [PATCH] Use simple copy for scratch-component.html Using the html webpack copy plugin meant that our scratch-component.html page ended up with script tags loading both web-component.js and PyodideWorker.js (corresponding to `entry` keys in webpack.config.js). We don't need those in scratch-component.html and we want to rule out whether their presence is causing the errors we're currently seeing when deploying editor-ui using github actions. --- webpack.config.js | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/webpack.config.js b/webpack.config.js index 43fce19cf..74fef52bf 100644 --- a/webpack.config.js +++ b/webpack.config.js @@ -137,14 +137,10 @@ module.exports = { template: "src/web-component.html", filename: "web-component.html", }), - new HtmlWebpackPlugin({ - inject: "body", - template: "src/scratch-component.html", - filename: "scratch-component.html", - }), new CopyWebpackPlugin({ patterns: [ { from: "public", to: "" }, + { from: "src/scratch-component.html", to: "scratch-component.html" }, { from: "scratch/dist/main.js", to: "scratch.js" }, // { from: "scratch/node_modules/scratch-gui/dist/static/blocks-media/default/*.svg", to: "static/blocks-media/default/[name][ext]" }, // { from: "scratch/node_modules/scratch-gui/dist/static/blocks-media/high-contrast/*.svg", to: "static/blocks-media/high-contrast/[name][ext]" },