Skip to content

Commit 41c13b5

Browse files
committed
Try to remove unused spec/dummy dependencies
1 parent 5765b58 commit 41c13b5

File tree

3 files changed

+739
-42
lines changed

3 files changed

+739
-42
lines changed

knip.ts

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,11 @@ const config: KnipConfig = {
5454
'@rescript/react',
5555
// The Babel plugin fails to detect it
5656
'babel-plugin-transform-react-remove-prop-types',
57-
// Temporary!
58-
'.*',
57+
// The below dependencies are not detected by the Webpack plugin
58+
// due to the config issue.
59+
'expose-loader',
60+
'imports-loader',
61+
'sass-resources-loader',
5962
],
6063
},
6164
},

spec/dummy/config/webpack/commonWebpackConfig.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ const sassLoaderConfig = {
2424
const scssConfigIndex = baseClientWebpackConfig.module.rules.findIndex((config) =>
2525
'.scss'.match(config.test),
2626
);
27-
baseClientWebpackConfig.module.rules[scssConfigIndex].use.push(sassLoaderConfig);
27+
baseClientWebpackConfig.module.rules[scssConfigIndex]?.use.push(sassLoaderConfig);
2828

2929
// add jquery
3030
const exposeJQuery = {

0 commit comments

Comments
 (0)