Pergunta

Eu uso o Web Essentials 2012 no vs 2012.

Quando compilar menos arquivo com conteúdo como esse:

/* HEADER */



.header{
    background: red;
}



/* FOOTER */



.footer{
    background: black;
}

... para o arquivo CSS, o resultado é o seguinte:

/* HEADER */
.header{
    background: red;
}
/* FOOTER */
.footer{
    background: black;
}

Existe uma opção "Mantenha a formatação original" ou o conjunto de opções com que eu poderia manter a formatação original?

Foi útil?

Solução

Sort of...

If your main desire is to keep the "gap" between the comment and the style for easier visual recognition, then in most cases this should work (unless perhaps you minify the code), because within the comment it will preserve the formatting of the empty lines down to the new position of the end comment marker */:

/* FOOTER *


*/
.footer{
    background: black;
}

That's about as close as you can get. Note: I have not actually tested this with Web Essentials, just on the less2css.org compiler.

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top