<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:dc="http://purl.org/dc/elements/1.1/" version="2.0"><channel><description>Front-end development minutiæ</description><title>dropshado.ws</title><generator>Tumblr (3.0; @dropshadows)</generator><link>https://dropshado.ws/</link><item><title>IE unloaded img size</title><description>&lt;p&gt;Internet Explorer 11, unlike Chrome or Firefox, renders a small 28px x 32px placeholder for an unloaded image. This might getcha if you are using responsive sizing &lt;code&gt;img { width: 100% }&lt;/code&gt;. Other browsers will render a full-width unloaded image with 0 height, but IE11 will render it large, maintain its size ratio. &lt;a href="http://codepen.io/desandro/pen/meZJJK?editors=110"&gt;See pen&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="http://codepen.io/desandro/pen/meZJJK?editors=110"&gt;&lt;img src="http://i.imgur.com/OJX5jG8.png" alt="Unloaded image demo on IE11"/&gt;&lt;/a&gt;&lt;/p&gt;</description><link>https://dropshado.ws/post/133934066982</link><guid>https://dropshado.ws/post/133934066982</guid><pubDate>Wed, 25 Nov 2015 11:27:01 -0500</pubDate><category>ie</category></item><item><title>event.currentTarget vs. this</title><description>&lt;p&gt;You can use &lt;a href="https://api.jquery.com/event.currentTarget/"&gt;&lt;code&gt;event.currentTarget&lt;/code&gt; in place of &lt;code&gt;this&lt;/code&gt; inside jQuery event handlers&lt;/a&gt;&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;$('.button').on( 'click', function( event ) {
  console.log( event.currentTarget === this ); // true
});
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;While &lt;code&gt;this&lt;/code&gt; inside event handlers has become commonplace, I feel the &lt;code&gt;event.currentTarget&lt;/code&gt; pattern is more obvious. It is more compatible working with other patterns that use &lt;code&gt;this&lt;/code&gt; differently.&lt;/p&gt;</description><link>https://dropshado.ws/post/132543858377</link><guid>https://dropshado.ws/post/132543858377</guid><pubDate>Wed, 04 Nov 2015 11:55:25 -0500</pubDate><category>jQuery</category><category>JavaScript</category></item><item><title>Scripts at bottom vs. document ready</title><description>&lt;a href="http://stackoverflow.com/a/6026730/182183"&gt;Scripts at bottom vs. document ready&lt;/a&gt;: &lt;p&gt;Including &lt;code&gt;&lt;script&gt;&lt;/code&gt;s at bottom of the page is just as good as wrapping their code in &lt;code&gt;$(document).ready()&lt;/code&gt;.&lt;/p&gt;</description><link>https://dropshado.ws/post/131698370407</link><guid>https://dropshado.ws/post/131698370407</guid><pubDate>Thu, 22 Oct 2015 15:01:33 -0400</pubDate><category>JavaScript</category></item><item><title>HTML5 video autoplay DOM change WebKit bug</title><description>&lt;p&gt;WebKit/Blink has a bug where making a &lt;a href="https://bugs.webkit.org/show_bug.cgi?id=45188"&gt;DOM change to video elements will pause the video&lt;/a&gt;. This can prevent or stop video &lt;code&gt;autoplay&lt;/code&gt;. &lt;a href="http://stackoverflow.com/a/26907606/182183"&gt;Arnaud Leyder has a solid explanation on Stack Overflow&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;The hack fix is to re-trigger &lt;code&gt;.play()&lt;/code&gt; on the video after the DOM change has been made.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;// make DOM change to video
elem.appendChild( video );
// trigger .play() to resume autoplay for WebKit
video.play();
&lt;/code&gt;&lt;/pre&gt;

&lt;p data-height="380" data-theme-id="0" data-slug-hash="RNBxXq" data-default-tab="result" data-user="desandro" class="codepen"&gt;See the Pen &lt;a href="http://codepen.io/desandro/pen/RNBxXq/"&gt;html5 video autoplay DOM change WebKit bug&lt;/a&gt; by David DeSandro (&lt;a href="http://codepen.io/desandro"&gt;@desandro&lt;/a&gt;) on &lt;a href="http://codepen.io"&gt;CodePen&lt;/a&gt;.&lt;/p&gt;

&lt;script async src="//assets.codepen.io/assets/embed/ei.js"&gt;&lt;/script&gt;</description><link>https://dropshado.ws/post/112695083527</link><guid>https://dropshado.ws/post/112695083527</guid><pubDate>Wed, 04 Mar 2015 09:35:34 -0500</pubDate><category>video</category><category>WebKit</category></item><item><title>padding-bottom border-box border bug</title><description>&lt;p&gt;You can use &lt;code&gt;padding-bottom&lt;/code&gt; as a way to set height of an element based on its parent width, so that it is proportional with its own width.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;/* item sized as a square 1/3 size of container */
.item {
  width: 33.3%;
  padding-bottom: 33.3%;
}
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;If you are using &lt;code&gt;box-sizing: border-box&lt;/code&gt; and the element has border, you would expect that element to remain a perfect square.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;.item {
  width: 33.3%;
  padding-bottom: 33.3%;
  border: 2px solid;
}
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;But that&amp;rsquo;s not the case. Because the height is faked with &lt;code&gt;padding-bottom&lt;/code&gt;, it&amp;rsquo;s not actually setting its height. Consequently, the height of the border is added on top of the &lt;code&gt;padding-bottom&lt;/code&gt; height.&lt;/p&gt;

&lt;p&gt;This can be resolved either by using &lt;code&gt;outline&lt;/code&gt; instead of border, or using &lt;code&gt;calc&lt;/code&gt; to account for the border size.&lt;/p&gt;

&lt;p data-height="419" data-theme-id="0" data-slug-hash="wBXqLB" data-default-tab="result" data-user="desandro" class="codepen"&gt;See the Pen &lt;a href="http://codepen.io/desandro/pen/wBXqLB/"&gt;bug with padding-bottom, border, and box-sizing: border-box&lt;/a&gt; by David DeSandro (&lt;a href="http://codepen.io/desandro"&gt;@desandro&lt;/a&gt;) on &lt;a href="http://codepen.io"&gt;CodePen&lt;/a&gt;.&lt;/p&gt;

&lt;script async src="//assets.codepen.io/assets/embed/ei.js"&gt;&lt;/script&gt;</description><link>https://dropshado.ws/post/112220816147</link><guid>https://dropshado.ws/post/112220816147</guid><pubDate>Fri, 27 Feb 2015 08:26:22 -0500</pubDate><category>CSS</category></item><item><title>Match CSS animation keyframe transforms</title><description>&lt;p&gt;My loader spinner wasn&amp;rsquo;t spinning.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;.loader-spinner {
  animation: spinLoader 600ms steps(12, end) infinite;
}

@keyframes spinLoader {
  from { transform: translate( -50%, -50% ); }
  to { transform: translate( -50%, -50% ) rotate(1turn); }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;The problem was that the keyframes for &lt;code&gt;transform&lt;/code&gt; need to match. Even though there&amp;rsquo;s an implicit &lt;code&gt;rotate(0turn)&lt;/code&gt; in the &lt;code&gt;transform&lt;/code&gt; value, it&amp;rsquo;s required to be explicit for animation keyframes.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;@keyframes spinLoader {
  /* match transform values */
  from { transform: translate( -50%, -50% ) rotate(0turn); }
  to { transform: translate( -50%, -50% ) rotate(1turn); }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;p data-height="268" data-theme-id="0" data-slug-hash="wBPEXP" data-default-tab="result" data-user="desandro" class="codepen"&gt;See the Pen &lt;a href="http://codepen.io/desandro/pen/wBPEXP/"&gt;loader spinner with CSS animation&lt;/a&gt; by David DeSandro (&lt;a href="http://codepen.io/desandro"&gt;@desandro&lt;/a&gt;) on &lt;a href="http://codepen.io"&gt;CodePen&lt;/a&gt;.&lt;/p&gt;

&lt;script async src="//assets.codepen.io/assets/embed/ei.js"&gt;&lt;/script&gt;</description><link>https://dropshado.ws/post/110480258337</link><guid>https://dropshado.ws/post/110480258337</guid><pubDate>Sun, 08 Feb 2015 17:35:15 -0500</pubDate><category>CSS</category><category>animation</category><category>transforms</category></item><item><title>jQuery event trigger namespace</title><description>&lt;p&gt;&lt;a href="http://css-tricks.com/namespaced-events-jquery/"&gt;jQuery event namespaces&lt;/a&gt; allow you to separate event listeners.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;// bind click listeners
$element.on( 'click.alpha', function() {
  console.log('Alpha click');
});
$element.on( 'click.beta', function() {
  console.log('Beta click');
});
// unbind alpha click listener only
$element.off('click.alpha');
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;&lt;strong&gt;EDIT&lt;/strong&gt; &lt;strong&gt;The rest of this post is false&lt;/strong&gt; I had thought I verified this, but alas, no. Triggering with a namespace will not trigger that event &lt;em&gt;without&lt;/em&gt; the namespace.&lt;/p&gt;

&lt;hr&gt;

&lt;p&gt;They can also be used when triggering events, to specify where that event came from.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;$element.trigger('click.pluginName')
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;I&amp;rsquo;m using namespace triggering in &lt;a href="http://flickity.metafizzy.co"&gt;Flickity&lt;/a&gt;, as a way to distinguish Flickity&amp;rsquo;s &lt;code&gt;select&lt;/code&gt; event from the &lt;a href="https://developer.mozilla.org/en-US/docs/Web/Events/select"&gt;native &lt;code&gt;select&lt;/code&gt; event&lt;/a&gt;.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;// create jQuery event from original event object
var $event = jQuery.Event( event );
// set type, like select.flickity
$event.type = type + '.flickity';
this.$element.trigger( $event, args );
&lt;/code&gt;&lt;/pre&gt;</description><link>https://dropshado.ws/post/109695906602</link><guid>https://dropshado.ws/post/109695906602</guid><pubDate>Sat, 31 Jan 2015 14:32:00 -0500</pubDate><category>jQuery</category><category>events</category><category>JavaScript</category></item><item><title>Object.prototype.watch()</title><description>&lt;p&gt;&lt;a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/watch"&gt;Firefox has native &lt;code&gt;.watch()&lt;/code&gt; method&lt;/a&gt;.&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;The watch() method watches for a property to be assigned a value and runs a function when that occurs.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Interestingly, it&amp;rsquo;s special to Firefox.&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;Warning: Generally you should avoid using watch() and unwatch() when possible. These two methods are implemented only in Gecko, and they&amp;rsquo;re intended primarily for debugging use.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;I discovered this when I was using &lt;code&gt;watch&lt;/code&gt; for an option property name &lt;code&gt;options.watch = true&lt;/code&gt;. My stuff worked fine in Chrome &amp;amp; Safari, but it was absolutely broken in Firefox.&lt;/p&gt;</description><link>https://dropshado.ws/post/108044246182</link><guid>https://dropshado.ws/post/108044246182</guid><pubDate>Tue, 13 Jan 2015 22:37:43 -0500</pubDate><category>JavaScript</category><category>Firefox</category></item><item><title>Reinstall IE8 ievms</title><description>&lt;p&gt;I use &lt;a href="https://github.com/xdissent/ievms/"&gt;ievms&lt;/a&gt; to browser test Internet Explorer. Every couple of months, the IE8 VM expires (&lt;em&gt;This copy of Windows must be activated&amp;hellip;&lt;/em&gt;). The only solution is to &lt;a href="https://github.com/xdissent/ievms/issues/22#issuecomment-20616370"&gt;reinstall the VM&lt;/a&gt;. ievms maintainer xdissent also made &lt;a href="http://xdissent.github.io/iectrl/"&gt;iectrl&lt;/a&gt;, a command line tool to make stuff like this easier.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;iectrl reinstall 8
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;I tried removing &lt;code&gt;.ievms/&lt;/code&gt; files, and re-installing via the &lt;a href="https://github.com/xdissent/ievms/#quickstart"&gt;bash script&lt;/a&gt;. No dice. &lt;code&gt;iectrl&lt;/code&gt; is the way to go.&lt;/p&gt;</description><link>https://dropshado.ws/post/107687889727</link><guid>https://dropshado.ws/post/107687889727</guid><pubDate>Sat, 10 Jan 2015 08:44:17 -0500</pubDate><category>IE</category></item><item><title>moveChildren</title><description>&lt;p&gt;To move all children from one element into another.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;function moveChildren( fromElem, toElem ) {
  while ( fromElem.children.length ) {
    toElem.appendChild( fromElem.children[0] );
  }
}
// move all children in alpha into beta
moveChildren( alpha, beta )
&lt;/code&gt;&lt;/pre&gt;</description><link>https://dropshado.ws/post/107523035307</link><guid>https://dropshado.ws/post/107523035307</guid><pubDate>Thu, 08 Jan 2015 14:34:00 -0500</pubDate><category>JavaScript</category></item><item><title>Absolute text wrap</title><description>&lt;p&gt;When an element is positioned partly outside the window AND that element does not have a width set, its text will wrap inside the window.&lt;/p&gt;

&lt;p data-height="400" data-theme-id="0" data-slug-hash="nrKew" data-default-tab="result" class="codepen"&gt;See the Pen &lt;a href="http://codepen.io/desandro/pen/nrKew/"&gt;absolute text wrap&lt;/a&gt; by David DeSandro (&lt;a href="http://codepen.io/desandro"&gt;@desandro&lt;/a&gt;) on &lt;a href="http://codepen.io"&gt;CodePen&lt;/a&gt;.&lt;/p&gt;

&lt;script async="true" src="http://codepen.io/assets/embed/ei.js"&gt; &lt;/script&gt;

&lt;p&gt;This behavior threw me for a loop on &lt;a href="https://github.com/desandro/masonry/issues/427"&gt;this Masonry bug&lt;/a&gt;.&lt;/p&gt;</description><link>https://dropshado.ws/post/93166549422</link><guid>https://dropshado.ws/post/93166549422</guid><pubDate>Mon, 28 Jul 2014 21:50:08 -0400</pubDate><category>CSS</category></item><item><title>Conditional CSS doesn't work in Chrome</title><description>&lt;p&gt;&lt;a href="http://adactio.com/journal/5429"&gt;Jeremy Keith&amp;rsquo;s Conditional CSS technique&lt;/a&gt; currently doesn&amp;rsquo;t work in Chrome.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;@media all and (min-width: 45em) {
    body:after {
        content: 'widescreen';
        display: none;
    }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;The problem is with how &lt;a href="https://code.google.com/p/chromium/issues/detail?id=236603"&gt;Chrome will not generate pseudo elements&lt;/a&gt; when set to &lt;code&gt;display: none&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;My current solution/hack is to fallback to the &lt;code&gt;head font-size&lt;/code&gt; code, as Opera now supports this.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;@media screen and (min-width: 45em) {
    head {
        font-family: widescreen;
    }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;Thx &lt;a href="https://twitter.com/overflowhidden/status/444020047552712704"&gt;@overflowhidden for the assist&lt;/a&gt;.&lt;/p&gt;</description><link>https://dropshado.ws/post/79494424279</link><guid>https://dropshado.ws/post/79494424279</guid><pubDate>Thu, 13 Mar 2014 18:03:49 -0400</pubDate><category>Chrome</category><category>CSS</category></item><item><title>Canvas spinning fan</title><description>&lt;iframe class="vine-embed" src="https://vine.co/v/MZImrrUu6jL/embed/simple" width="480" height="480" frameborder="0"&gt; &lt;/iframe&gt;

&lt;script async="true" src="//platform.vine.co/static/scripts/embed.js"&gt; &lt;/script&gt;

&lt;p&gt;The white noise you hear in &lt;a href="https://vine.co/v/MZImrrUu6jL"&gt;this Vine&lt;/a&gt; is the sound of my laptop fan whirling away at top speed. This animation is rendered in &lt;code&gt;&amp;lt;canvas&amp;gt;&lt;/code&gt;, in Chrome. While the animation does have thousands of particles being rendered, I hadn&amp;rsquo;t expected the top-speed fan.&lt;/p&gt;

&lt;p&gt;I&amp;rsquo;ve been able to pinpoint its cause. The animation was using the width of an image, &lt;code&gt;this.img.width&lt;/code&gt;, for every particle, every frame. Setting this value to a separate property &lt;code&gt;this.imgWidth&lt;/code&gt; has slowed down the fan significantly. I speculate that this issue is similar to &lt;a href="http://blog.letitialew.com/post/30425074101/repaints-and-reflows-manipulating-the-dom-responsibly"&gt;reflow triggers&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Clearly, debugging via hardware machinations is not a good strategy. I still struggle with making sense of anything in the Chrome Developer Tools around rendering performance &amp;ndash; especially for a rendering like this one, involving thousands of particles over thousands of frames.&lt;/p&gt;</description><link>https://dropshado.ws/post/77906307928</link><guid>https://dropshado.ws/post/77906307928</guid><pubDate>Wed, 26 Feb 2014 09:12:21 -0500</pubDate><category>canvas</category></item><item><title>Firefox doesn't support canvas composite darker</title><description>&lt;p&gt;&lt;a href="https://bugzilla.mozilla.org/show_bug.cgi?id=571532"&gt;Firefox doesn&amp;rsquo;t support canvas &lt;code&gt;globalCompositeOperation&lt;/code&gt; &lt;code&gt;darker&lt;/code&gt;&lt;/a&gt;. As it turns out, the &lt;code&gt;darker&lt;/code&gt; composite value was removed from the &lt;a href="http://www.w3.org/html/wg/drafts/2dcontext/html5_canvas/#dom-context-2d-globalcompositeoperation"&gt;canvas spec&lt;/a&gt; in 2007. See &lt;a href="https://developer.mozilla.org/samples/canvas-tutorial/6_1_canvas_composite.html"&gt;the globalCompositeOperation examples on MDN&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;The closest solution is to use &lt;code&gt;difference&lt;/code&gt; (which oddly enough isn&amp;rsquo;t in the spec), which Firefox (currently v28) does support. But &lt;code&gt;difference&lt;/code&gt; is different from &lt;code&gt;darker&lt;/code&gt;. &lt;code&gt;difference&lt;/code&gt; subtracts channel values, &lt;code&gt;darker&lt;/code&gt; multiplies them. If you&amp;rsquo;re using primary colors (&lt;code&gt;#f00&lt;/code&gt;, &lt;code&gt;#f0f&lt;/code&gt;, etc.) it may work.&lt;/p&gt;

&lt;p&gt;IE10 supports neither.&lt;/p&gt;

&lt;p data-height="440" data-theme-id="0" data-slug-hash="tCyEF" data-default-tab="result" class="codepen"&gt;See the Pen &lt;a href="http://codepen.io/desandro/pen/tCyEF"&gt;darker/difference canvas composite&lt;/a&gt; by David DeSandro (&lt;a href="http://codepen.io/desandro"&gt;@desandro&lt;/a&gt;) on &lt;a href="http://codepen.io"&gt;CodePen&lt;/a&gt;.&lt;/p&gt;

&lt;script async="true" src="//codepen.io/assets/embed/ei.js"&gt;''&lt;/script&gt;</description><link>https://dropshado.ws/post/77229081704</link><guid>https://dropshado.ws/post/77229081704</guid><pubDate>Wed, 19 Feb 2014 20:27:00 -0500</pubDate><category>canvas</category><category>Firefox</category><category>hasfiddle</category></item><item><title>Safari rounds off fractional pixels</title><description>&lt;p&gt;I&amp;rsquo;m looking to measure the width of an element with &lt;code&gt;width: 66.666%&lt;/code&gt;, whose container is &lt;code&gt;width: 300px&lt;/code&gt;. Most browsers return a fractional pixel value, i.e. &lt;code&gt;199.98px&lt;/code&gt;. Safari rounds off the fractional pixel value to &lt;code&gt;199px&lt;/code&gt;. It&amp;rsquo;s a bit odd, as I would expect it would at least round up to &lt;code&gt;200px&lt;/code&gt; when the value is that close.&lt;/p&gt;

&lt;p&gt;See demo:&lt;/p&gt;

&lt;p data-height="268" data-theme-id="0" data-slug-hash="CEfJF" data-default-tab="result" class="codepen"&gt;See the Pen &lt;a href="http://codepen.io/desandro/pen/CEfJF"&gt;getComputedStyle width 66.666%&lt;/a&gt; by David DeSandro (&lt;a href="http://codepen.io/desandro"&gt;@desandro&lt;/a&gt;) on &lt;a href="http://codepen.io"&gt;CodePen&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;I&amp;rsquo;ve opened &lt;a href="https://bugs.webkit.org/show_bug.cgi?id=126844"&gt;WebKit bug #126844&lt;/a&gt; to capture this behavior.&lt;/p&gt;

&lt;p&gt;I have found that using &lt;code&gt;calc()&lt;/code&gt; values produces more expected results. If I change the width of the element to &lt;code&gt;width: calc( 100% * 2 / 3 )&lt;/code&gt;, Safari returns with &lt;code&gt;200px&lt;/code&gt;. It&amp;rsquo;s still problematic, but it&amp;rsquo;s an improvement.&lt;/p&gt;

&lt;p data-height="268" data-theme-id="0" data-slug-hash="CKwfd" data-default-tab="result" class="codepen"&gt;See the Pen &lt;a href="http://codepen.io/desandro/pen/CKwfd"&gt;getComputedStyle width calc( 100% * 2/3)&lt;/a&gt; by David DeSandro (&lt;a href="http://codepen.io/desandro"&gt;@desandro&lt;/a&gt;) on &lt;a href="http://codepen.io"&gt;CodePen&lt;/a&gt;.&lt;/p&gt;

&lt;script async="true" src="http://codepen.io/assets/embed/ei.js"&gt; &lt;/script&gt;</description><link>https://dropshado.ws/post/73100695877</link><guid>https://dropshado.ws/post/73100695877</guid><pubDate>Sun, 12 Jan 2014 11:43:51 -0500</pubDate><category>Safari</category><category>hasfiddle</category></item><item><title>Static site S3 workflow</title><description>&lt;p&gt;After a snafu with my previous hosting company, I&amp;rsquo;ve been using &lt;a href="http://docs.aws.amazon.com/AmazonS3/latest/dev/WebsiteHosting.html"&gt;Amazon&amp;rsquo;s static site service on S3&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Site is built in &lt;code&gt;build/&lt;/code&gt;. I&amp;rsquo;ve been using &lt;a href="http://gruntjs.com/"&gt;Grunt&lt;/a&gt; mostly, but this would work just as well for Jekyll sites.&lt;/p&gt;

&lt;p&gt;I use &lt;a href="http://s3tools.org/s3cmd"&gt;s3cmd&lt;/a&gt; to transfer the files. Everything in &lt;code&gt;build/&lt;/code&gt; gets uploaded.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;s3cmd sync build/. s3://masonry.desandro.com
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;This command is saved in a Makefile. See &lt;a href="https://github.com/desandro/masonry-docs/blob/master/Makefile"&gt;masonry-docs/Makefile&lt;/a&gt;.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;make deploy
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;So after set up, making a site takes one or two commands&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;grunt
make deploy
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;See this workflow in use:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="http://github.com/desandro/masonry-docs"&gt;Masonry docs&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/metafizzy/isotope-docs"&gt;Isotope docs&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/desandro/draggabilly/tree/site"&gt;Draggabilly site&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;hr&gt;

&lt;p&gt;This workflow is especially straightforward. At one time I did try a git post-receive hook (&lt;a href="http://nicolasgallagher.com/simple-git-deployment-strategy-for-static-sites/"&gt;like one Nicolas Gallagher explains&lt;/a&gt;), but this felt murky, _ssh_ing to a remote box, managing two git instances. Sticking with straight-up file transfering is dumb enough that I can understanding it. Adding a separate workflow for deployment on top of git seems like duplicated effort, but there&amp;rsquo;s a benefit to separating these tasks. In my head, they&amp;rsquo;re separate.&lt;/p&gt;</description><link>https://dropshado.ws/post/72044078763</link><guid>https://dropshado.ws/post/72044078763</guid><pubDate>Thu, 02 Jan 2014 23:04:05 -0500</pubDate><category>S3</category><category>deploy</category></item><item><title>Transition end propertyName</title><description>&lt;p&gt;When listening to transition End event, the &lt;a href="http://www.w3.org/TR/css3-transitions/#Events-TransitionEvent-propertyName"&gt;&lt;code&gt;event&lt;/code&gt; object comes with &lt;code&gt;propertyName&lt;/code&gt;&lt;/a&gt;. This is useful when detecting just what transition has completed.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;elem.addEventListener( 'transitionend' function( event ) {
  console.log( event.propertyName + 'transition completed' );
});
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;Also interesting is how the transition end event will only trigger once if a property gets changed again, during a previous transition.&lt;/p&gt;

&lt;p data-height="268" data-theme-id="0" data-slug-hash="EHpct" data-user="desandro" data-default-tab="result" class="codepen"&gt;See the Pen &lt;a href="http://codepen.io/desandro/pen/EHpct"&gt;transtionEnd&lt;/a&gt; by David DeSandro (&lt;a href="http://codepen.io/desandro"&gt;@desandro&lt;/a&gt;) on &lt;a href="http://codepen.io"&gt;CodePen&lt;/a&gt;&lt;/p&gt;

&lt;script async="true" src="http://codepen.io/assets/embed/ei.js"&gt;&lt;/script&gt;</description><link>https://dropshado.ws/post/60136524817</link><guid>https://dropshado.ws/post/60136524817</guid><pubDate>Mon, 02 Sep 2013 21:43:27 -0400</pubDate><category>transitions</category><category>hasfiddle</category></item><item><title>Flex box with collapsed height</title><description>&lt;p&gt;By default, &lt;a href="http://css-tricks.com/using-flexbox/"&gt;flex box&lt;/a&gt; makes item elements inherit the height of their container. To disable this behavior, and collapse item heights, use &lt;code&gt;align: start&lt;/code&gt; (or the proper variation there-of).&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;.row {
  /* flex box */
  display: -webkit-box;
  display: -moz-box;
  display: -ms-flexbox;
  display: -webkit-flex;
  display: flex;   
  /* align start, disable vertical height */
  -webkit-box-align: start;
     -moz-box-align: start; /* FF &amp;lt;=20 */
     -ms-flex-align: start; /* IE10 */
  -webkit-align-items: flex-start;
          align-items: flex-start;
}
&lt;/code&gt;&lt;/pre&gt;

&lt;pre class="codepen" data-height="300" data-type="result" data-href="zhcKu" data-user="desandro" data-safe="true"&gt;&lt;code&gt;&lt;/code&gt;&lt;a href="http://codepen.io/desandro/pen/zhcKu"&gt;Check out this Pen!&lt;/a&gt;&lt;/pre&gt;

&lt;script async="true" src="http://codepen.io/assets/embed/ei.js"&gt; &lt;/script&gt;</description><link>https://dropshado.ws/post/51574113930</link><guid>https://dropshado.ws/post/51574113930</guid><pubDate>Tue, 28 May 2013 14:33:41 -0400</pubDate><category>CSS</category><category>flexbox</category><category>hasfiddle</category></item><item><title>Refresh button in IE developer tools</title><description>&lt;p&gt;Internet Explorer&amp;rsquo;s HTML developer tool will not display changes to the DOM until you click the Refresh button. This goes for newly appended elements, changes to classes, and other changes.&lt;/p&gt;

&lt;p&gt;&lt;img src="http://i.imgur.com/2cMTKQI.png" alt="Internet Explorer developer tool refresh button"/&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="http://cdpn.io/Jegfu"&gt;Try out this demo&lt;/a&gt;. New items won&amp;rsquo;t appear in the inspector until you refresh.&lt;/p&gt;

&lt;p&gt;Thx to &lt;a href="https://github.com/desandro/masonry/issues/216#issuecomment-15504011"&gt;KillianJK on GitHub&lt;/a&gt; for putting in the due diligence to get to the bottom of this.&lt;/p&gt;</description><link>https://dropshado.ws/post/46430148565</link><guid>https://dropshado.ws/post/46430148565</guid><pubDate>Wed, 27 Mar 2013 13:10:09 -0400</pubDate><category>IE</category><category>hasexample</category></item><item><title>event.target on resize in Opera</title><description>&lt;p&gt;In Opera, on &lt;code&gt;resize&lt;/code&gt;, &lt;code&gt;event.target&lt;/code&gt; is &lt;code&gt;document&lt;/code&gt;, not &lt;code&gt;window&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="http://jsfiddle.net/desandro/dCug7/"&gt;See fiddle&lt;/a&gt;.&lt;/p&gt;</description><link>https://dropshado.ws/post/46202492495</link><guid>https://dropshado.ws/post/46202492495</guid><pubDate>Sun, 24 Mar 2013 19:08:40 -0400</pubDate><category>Opera</category></item></channel></rss>
