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

Automating Theme Development - LoopConf Edition

Automating Theme Development - LoopConf Edition

Take a tip from the machines and take away the tedious or otherwise painful parts of your theme development workflow via the latest automating tools and techniques. This session covers tools for each part of the theme development workflow ranging from CSS preprocessors like Sass to task runners like Grunt and Gulp.

Zoe Rooney

May 07, 2015
Tweet

More Decks by Zoe Rooney

Other Decks in Programming

Transcript

  1. - B. F. Skinner “The real problem is not whether

    machines think but whether men do.”
  2. 1. Find and replace; loooooong CSS files
 2. CanIUse-ing browser

    prefixes
 3. Optimize images; lint, organize, minify JS ACTIVE WORK
  3. 1. Find and replace; loooooong CSS files
 2. CanIUse-ing browser

    prefixes
 3. Processing things like Sass, or running other tasks ACTIVE WORK
  4. #primary { float: left; width: 600px; &.right { float: right;

    } &.full-width { float: none; width: 100%; } h1 { text-align: center; } }
  5. $bg: #fff; // Dimensions $max-width: 1100px; $side-padding: 15px; $max-outer-width: $width

    + $side-padding // Typography $main: 'Open Sans', sans-serif; $text: #333; // Media Queries $m: 880px; $s: 760px; $xs: 480px;
  6. { "repository": { "type": "git", "url": "https://github.com/zoerooney/Emi" }, "dependencies": {

    "gulp": "*", "gulp-ruby-sass": "*", "gulp-autoprefixer": "*", "gulp-minify-css": "*", "gulp-livereload": "*" } }
  7. 1. Get the starter theme (_s, Bones, Emi)
 2. Replace

    text strings throughout 3. Install tools via NPM PROJECT SETUP
  8. 1. Get the starter theme (_s, Bones, Emi)
 2. Replace

    text strings throughout 3. Install tools via NPM PROJECT SETUP
  9. $ git init $ git add -A $ git commit

    -m "initial commit" theme-folder
  10. INSTALL ALL THE THINGS ‣ Node.js via nodejs.org ‣ Ruby

    (PC only, comes with Macs) ‣ Sass via sass-lang.com directions ‣ Git via instructions on git- scm.com ‣ Gulp via NPM ‣ Yeoman via NPM