From 5bade323f6b7bf422c1feaa61a3de32ede824251 Mon Sep 17 00:00:00 2001 From: Przemyslaw Falowski Date: Fri, 22 May 2020 14:00:44 +0200 Subject: [PATCH] fix: set correct clean-css import --- src/postcss-clean.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/postcss-clean.ts b/src/postcss-clean.ts index b2bbd36..ac1ff60 100644 --- a/src/postcss-clean.ts +++ b/src/postcss-clean.ts @@ -1,5 +1,7 @@ import * as postcss from 'postcss' -import CleanCSS from 'clean-css' +// ESM import of clean-css breaks test/runtime check this fix for reference: +// https://github.com/vuejs/vue-component-compiler/pull/103#issuecomment-632676899 +const CleanCSS = require('clean-css') export default postcss.plugin('clean', (options: any) => { const clean = new CleanCSS({ compatibility: 'ie9', ...options })