fix(webpack): font-family hex issue (#7763)

This commit is contained in:
Ahad Birang 2020-07-26 20:18:58 +04:30 committed by GitHub
parent 6af76334c5
commit 4f27cdded8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -79,7 +79,13 @@ export default class PostcssConfig {
// https://github.com/csstools/postcss-preset-env
'postcss-preset-env': this.preset || {},
cssnano: dev ? false : { preset: 'default' }
cssnano: dev ? false : {
preset: ['default', {
// Keep quotes in font values to prevent from HEX conversion
// https://github.com/nuxt/nuxt.js/issues/6306
minifyFontValues: { removeQuotes: false }
}]
}
},
// Array, String or Function
order: 'presetEnvAndCssnanoLast'