mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-15 02:14:44 +00:00
34 lines
739 B
TypeScript
34 lines
739 B
TypeScript
import { defineUntypedSchema } from 'untyped'
|
|
|
|
export default defineUntypedSchema({
|
|
postcss: {
|
|
/**
|
|
* Options for configuring PostCSS plugins.
|
|
*
|
|
* https://postcss.org/
|
|
* @type {Record<string, any> & { autoprefixer?: any; cssnano?: any }}
|
|
*/
|
|
plugins: {
|
|
/**
|
|
* https://github.com/postcss/autoprefixer
|
|
*/
|
|
autoprefixer: {},
|
|
|
|
/**
|
|
* https://cssnano.github.io/cssnano/docs/config-file/#configuration-options
|
|
*/
|
|
cssnano: {
|
|
$resolve: async (val, get) => {
|
|
if (val || val === false) {
|
|
return val
|
|
}
|
|
if (await get('dev')) {
|
|
return false
|
|
}
|
|
return {}
|
|
},
|
|
},
|
|
},
|
|
},
|
|
})
|