Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

228
Visualizações
A simple way to remove newlines (line breaks) between CSS selectors

With gulp-beautify I'm optimizing files containing CSS for email, which means they can't have newlines between selectors, since there is a limit on the total number of lines allowed in some email clients. I've found Beautify has an option to add newlines between selectors, but it doesn't have a feature to remove them. If selector_separator_newline is false, it ignores newlines if present.

I'm building tasks for two outputs, minified, and beautified. Obviously, the minified version doesn't need this.

I could minify before I beautify, but that removes comments, and I need to preserve comments.

I could remove all new lines and then run Beautify, and I'm looking into doing that, but I feel like I'm missing something.

Is there a package, out-of-the-box, or otherwise simple way to remove all newlines / line breaks between selectors?

about 4 years ago · Juan Pablo Isaza
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda