lru-cache in style-rewriter prevents proper function with gulp-watch and postcss plugins
teleclimber opened this issue · 0 comments
teleclimber commented
style-rewriter.js makes use of a lru cache to avoid reprocessing CSS unnecessarily.
Unfortunately if you use additional PostCSS plugins and you depend on gulp.watch or similar to re-process your files as needed the lru cache prevents recompilation when recompilation is necessary.
In my case I use postcss-mixins with the mixinsDir option. I have all my mixins in a separate directory. Unfortunately vuefiy is not aware of this mixin dir, therefore on re-runs of vueify triggered by gulp-watch, the cached version of the processed CSS gets returned if all I changed was a mixin.
I disabled the lru cache in my fork of vueify and this fixes the problem.