问题
I'm using the latest Sass with Compass addon. I want my production code to include my "hard" comments, but after that I would like to have a line break.
/*! Generic elements and layout */
/* *********************************************** */
html
box-sizing: border-box
...
Should be outputted like this:
/* Generic elements and layout */
html{box-sizing: border-box}...
Is this a possibility? I would like to include licences from 3rd party things (flexbox etc.) like this in my code.
回答1:
No. This sort of thing would require a modification to Sass. You could use the short C style comment instead to get what is functionally the same thing:
/*! Generic elements and layout */
// ***********************************************
html
box-sizing: border-box
Comments preceded by double forward slash are never part of the generated CSS.
来源:https://stackoverflow.com/questions/16812933/line-breaks-after-hard-comments-in-sass