Skip to content

Commit c5e6373

Browse files
sebjacobschrislo
andcommitted
refactor: remove unused STATIC_PATH from webpack config
STATIC_PATH was introduced back in 2019 [1] as a way to allow consumers of scratch-gui (like ourselves) to customize the publicPath (where assets are served from when the JS is run in the browser). However it looks like this feature was removed/commented out [2] when they migrated to using the shared webpack config (from the npm package `scratch-webpack-configuration`). We would like to re-introduce this feature in order to fix an issue we have noticed with image assets failing to load as the browser is attempting to load thse assets from URLs relative to the webpack entry point (rather than from the root or `/scratch-gui`). Therefore I am removing this commented out code to make the existing config less confusing. [1] scratchfoundation@e2a2dcf0f [2] scratchfoundation@f1438f73e Co-Authored-By: Chris Lowis <[email protected]>
1 parent 77772b7 commit c5e6373

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

webpack.config.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,6 @@ const HtmlWebpackPlugin = require('html-webpack-plugin');
77

88
const ScratchWebpackConfigBuilder = require('scratch-webpack-configuration');
99

10-
// const STATIC_PATH = process.env.STATIC_PATH || '/static';
11-
1210
const baseConfig = new ScratchWebpackConfigBuilder(
1311
{
1412
rootPath: path.resolve(__dirname),

0 commit comments

Comments
 (0)