Skip to content

Commit

Permalink
Update getpostcssconfig.js
Browse files Browse the repository at this point in the history
  • Loading branch information
XGhozt committed Jan 20, 2021
1 parent 5565ca9 commit 8a39404
Showing 1 changed file with 10 additions and 8 deletions.
18 changes: 10 additions & 8 deletions packages/ckeditor5-dev-utils/lib/styles/getpostcssconfig.js
Expand Up @@ -19,21 +19,23 @@
*/
module.exports = function getPostCssConfig( options = {} ) {
const config = {
plugins: [
require( 'postcss-import' )(),
require( './themeimporter' )( options.themeImporter ),
require( 'postcss-mixins' )(),
require( 'postcss-nesting' )(),
require( './themelogger' )()
]
postcssOptions: {
plugins: [
require( 'postcss-import' )(),
require( './themeimporter' )( options.themeImporter ),
require( 'postcss-mixins' )(),
require( 'postcss-nesting' )(),
require( './themelogger' )()
]
}
};

if ( options.sourceMap ) {
config.sourceMap = 'inline';
}

if ( options.minify ) {
config.plugins.push( require( 'cssnano' )( {
config.postcssOptions.plugins.push( require( 'cssnano' )( {
preset: 'default',
autoprefixer: false,
reduceIdents: false
Expand Down

0 comments on commit 8a39404

Please sign in to comment.