Skip to content

Commit

Permalink
Merge pull request #5132 from dodona-edu/chore/speed-up-webpack
Browse files Browse the repository at this point in the history
  • Loading branch information
bmesuere authored Nov 13, 2023
2 parents 0f50f8b + bee1bc9 commit 622f35e
Showing 1 changed file with 14 additions and 1 deletion.
15 changes: 14 additions & 1 deletion config/webpack/webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,15 @@ const config = {
return modulePath.endsWith('.ts') && !modulePath.endsWith('test.ts');
},
exclude: /node_modules/,
use: ["babel-loader", "ts-loader"],
use: [
"babel-loader",
{
loader: 'ts-loader',
options: {
transpileOnly: true,
},
}
],
},
],
},
Expand Down Expand Up @@ -62,6 +70,11 @@ if (process.env.NODE_ENV === "development") {
config.devtool = "inline-source-map";
}

// disable terser minimization when running
if (process.env.RAILS_ENV === "test") {
config.optimization.minimize = false;
}

// Test, Staging and Production use default config

module.exports = config;

0 comments on commit 622f35e

Please sign in to comment.