{
// format: 'keep-breaks'
format: {
breaks: { // controls where to insert breaks
afterAtRule: true, // controls if a line break comes after an at-rule; e.g. `@charset`; defaults to `false`
afterBlockBegins: true, // controls if a line break comes after a block begins; e.g. `@media`; defaults to `false`
afterBlockEnds: true, // controls if a line break comes after a block ends, defaults to `false`
afterComment: true, // 注释之后
afterProperty: false, // 属性之后
afterRuleBegins: false, // `{` 之后是否要换行
afterRuleEnds: true, // `}`之后是否要换行
beforeBlockEnds: true, // 块之间是否要换行
betweenSelectors: true // `,`选择器之间是否要换行
},
indentBy: 0, // controls number of characters to indent with; defaults to `0`
indentWith: 'space', // controls a character to indent with, can be `'space'` or `'tab'`; defaults to `'space'`
spaces: { // controls where to insert spaces
aroundSelectorRelation: true, // controls if spaces come around selector relations; e.g. `div > a`; defaults to `false`
beforeBlockBegins: true, // controls if a space comes before a block begins; e.g. `.block {`; defaults to `false`
beforeValue: true // controls if a space comes before a value; e.g. `width: 1rem`; defaults to `false`
},
wrapAt: false // controls maximum line length; defaults to `false`
}
}
网友评论