Build Tools: Don't minimise CSS in the unminimised files.

Props pento.
Merges [43933] to trunk.
Fixes #45201.

git-svn-id: https://develop.svn.wordpress.org/trunk@44283 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Sergey Biryukov 2018-12-18 03:16:21 +00:00
parent 62a5cd343c
commit ba6691fea1
1 changed files with 1 additions and 1 deletions

View File

@ -165,7 +165,7 @@ module.exports = function( env = { environment: 'production', watch: false, forc
to: join( baseDir, `${ buildTarget }/css/dist/${ packageName }/` ),
flatten: true,
transform: ( content ) => {
if ( config.mode === 'production' ) {
if ( config.mode === 'production' && ! env.forceBuildTarget ) {
return postcss( [
require( 'cssnano' )( {
preset: 'default',