Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Introduction to CSS Best Practices - ThoughtWorks Agile Accelerator

Introduction to CSS Best Practices - ThoughtWorks Agile Accelerator

Share knowlegde time at ThoughtWorks Agile Accelerator.

Submitted by, Matheus Varella de Oliveira.
Linkedin: https://www.linkedin.com/in/matheus-varella-de-oliveira/
Email: [email protected]

Matheus Varella de Oliveira

September 21, 2017
Tweet

More Decks by Matheus Varella de Oliveira

Other Decks in Programming

Transcript

  1. O que vai rolar nesta sessão? 1. O que é

    CSS?(breve) 2. Sete boas(ótimas) práticas 3. Como ser o melhor? 4. Flexbox? 5. Como testar CSS?
  2. 1 O que é css? CSS is a language that

    describes the style of an HTML document. CSS describes how HTML elements should be displayed.(W3School) Cascading Style Sheet
  3. Como ser o melhor? Dicas OOCSS - Object Oriented CSS

    Pré-processadores(Sass, Less, Stylus) Guias para tornar o CSS escalável(Smacss, BEM, Atomic Design, SuitCSS e etc) Style Guide Google PostCSS(Uma ferramenta para transformar CSS em JavaScript)
  4. Parker(Stylesheet analysis tool) CSS Comb(mantém a ordem das propriedades conforme

    configurado) Stylelint (Style + lint = lint de style :D) Normalize (CSS Reset - “Normaliza” o CSS escrito para o padrão atual dos navegadores) SASS (em inglês, “syntactilly awesome stylesheets” ou “folhas de estilo sintaticamente incríveis”) Ferramentas “batata”
  5. Flexbox Em resumo, flexbox, é um novo modo de fazer

    o seus layout se adequar a diversos viewports. Este é conteúdo é 90% prático, então prefiro deixar esses links que são bem didáticos para quem tiver interesse em aprender mais. http://flexbox.help/ https://css-tricks.com/snippets/css/a-guide-to-flexbox/ https://developer.mozilla.org/pt-BR/docs/CSS/Usando_caixas_flexiveis_css
  6. Old way: Capibara + Selenium (Compara se existe o elemento

    que tu procura) #expect(page).to have_css(".btn-confirm"); New way: Quixote (https://github.com/jamesshore/quixote) Como testar css?
  7. https://tableless.com.br/6-estrategias-para-melhorar-a-organizacao-do-seu-css-2/ https://code.tutsplus.com/tutorials/30-css-best-practices-for-beginners--net-6741 https://1stwebdesigner.com/css-best-practices/ https://tableless.com.br/oocss-ou-css-do-jeito-certo/ https://smacss.com/ https://tableless.com.br/oocss-smacss-bem-dry-css-afinal-como-escrever-css/ https://suitcss.github.io/ http://sass-lang.com/ http://lesscss.org/ http://stylus-lang.com/

    https://google.github.io/styleguide/htmlcssguide.html http://getbem.com/introduction/ https://tableless.com.br/o-que-e-design-atomic/ http://postcss.org/ Links https://github.com/jamesshore/quixote https://github.com/katiefenn/parker http://csscomb.com/ https://github.com/stylelint/stylelint https://necolas.github.io/normalize.css/ http://flexbox.help/ https://css-tricks.com/snippets/css/a-guide-to-flexbox/ https://developer.mozilla.org/pt-BR/docs/CSS/Usando_caixas_flexiveis_css https://github.com/teamcapybara/capybara https://github.com/jamesshore/quixote https://stackoverflow.com/questions/342579/css-unit-testing