Files
105eb779ee fix(css): cachedPostcssConfig reused for multiple builds (#3906)
* fix(css): cachedPostcssConfig reused for multiple builds

* fix: add tests to demonstrate that PostCSS configs are not reused across projects

* fix: run everything in a single Jest test to ensure module cache isn't cleared

Co-authored-by: François Wouts <[email protected]>
2021-07-20 14:24:50 +02:00

16 lines
291 B
JavaScript

module.exports = {
plugins: [replacePinkWithGreen]
}
function replacePinkWithGreen() {
return {
postcssPlugin: 'replace-pink-with-green',
Declaration(decl) {
if (decl.value === 'pink') {
decl.value = 'green'
}
}
}
}
replacePinkWithGreen.postcss = true