Skip to content

Commit 52e6d3e

Browse files
committed
force a full rebuild on a global change
1 parent 9b48fd1 commit 52e6d3e

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

core/lib/patternlab.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -539,7 +539,6 @@ const patternlab_engine = function (config) {
539539
plutils.log.info("Incremental builds enabled.");
540540
} else {
541541
// needs to be done BEFORE processing patterns
542-
fs.removeSync(paths.public.patterns);
543542
fs.emptyDirSync(paths.public.patterns);
544543
}
545544

@@ -683,7 +682,7 @@ const patternlab_engine = function (config) {
683682

684683
this.events.on('patternlab-global-change', () => {
685684
if (!patternlab.isBusy) {
686-
options.cleanPublic = false;
685+
options.cleanPublic = true; //rebuild everything
687686
return this.build(callback, options);
688687
}
689688
return Promise.resolve();

0 commit comments

Comments
 (0)