Skip to content

Commit 3469cbb

Browse files
authored
Fix: Correct Usage of CleanWebpackPlugin (styleguidist#1565)
I was still using an option that no longer exists. Fixed to mimic the original behavior. The option `root` was removed in v2, but wasn't changed during the upgrade in styleguidist@9804259 It's deleting everything in the styleguidistDir folder which isn't the way it was before. After this change it only deletes files in build/.
1 parent 83fdb94 commit 3469cbb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/scripts/make-webpack-config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ export default function(
9898
},
9999
plugins: [
100100
new CleanWebpackPlugin({
101-
root: config.styleguideDir,
101+
cleanOnceBeforeBuildPatterns: [`${config.styleguideDir}/build/**/*`],
102102
verbose: config.verbose === true,
103103
} as any),
104104
],

0 commit comments

Comments
 (0)