mirror of
https://github.com/hanzoai/vite.git
synced 2026-10-30 19:36:16 +00:00
* 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]>
16 lines
291 B
JavaScript
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
|