.mixin (...) { // matches 0-N arguments
.mixin () { // matches exactly 0 arguments
.mixin (@a: 1) { // matches 0-1 arguments
.mixin (@a: 1, ...) { // matches 0-N arguments
.mixin (@a, ...) { // matches 1-N arguments
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| * Usages: | |
| * {{#set "content"}} | |
| * captured content | |
| * {{/set}} | |
| * My {{ content }} | |
| */ | |
| Handlebars.registerHelper('set', function(name, options) { | |
| this[name] = options.fn(this); | |
| return null; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* http://www.zeldman.com/2012/03/01/replacing-the-9999px-hack-new-image-replacement/ */ | |
| overflow: hidden; | |
| text-indent: 100%; | |
| white-space: nowrap; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * Filter out hard-coded width, height attributes on all images in WordPress. | |
| * https://gist.github.com/4557917 | |
| * | |
| * This version applies the function as a filter to the_content rather than send_to_editor. | |
| * Changes made by filtering send_to_editor will be lost if you update the image or associated post | |
| * and you will slowly lose your grip on sanity if you don't know to keep an eye out for it. | |
| * the_content applies to the content of a post after it is retrieved from the database and is "theme-safe". | |
| * (i.e., Your changes will not be stored permanently or impact the HTML output in other themes.) | |
| * |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @media only screen and (min-width: 320px) { | |
| /* Small screen, non-retina */ | |
| } | |
| @media | |
| only screen and (-webkit-min-device-pixel-ratio: 2) and (min-width: 320px), | |
| only screen and ( min--moz-device-pixel-ratio: 2) and (min-width: 320px), | |
| only screen and ( -o-min-device-pixel-ratio: 2/1) and (min-width: 320px), |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| class Tweets | |
| { | |
| /** | |
| * Cached results as key => value array | |
| */ | |
| private static $cache = array(); | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ko.applyBindings({ | |
| fastClickResult: ko.observable("Waiting..."), | |
| clickResult: ko.observable("Waiting..."), | |
| handleClick: function(self, event) { | |
| self.clickResult("Clicked!"); | |
| }, | |
| handleFastClick: function(self, event) { | |
| self.fastClickResult("Fast Clicked!"); | |
| } | |
| }); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @include keyframes(appear-and-roundify) { | |
| 0% { opacity: 0; @include border-radius(2px); } | |
| 100% { opacity: 1; @include border-radius(10px); } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Windows Registry Editor Version 5.00 | |
| [HKEY_CLASSES_ROOT\Directory\shell\mintty] | |
| @="Open mintty Here" | |
| [HKEY_CLASSES_ROOT\Directory\shell\mintty\command] | |
| @="c:\\cygwin\\bin\\mintty.exe -e /bin/xhere /bin/bash.exe \"%L\"" | |
| [HKEY_CLASSES_ROOT\Drive\shell\mintty] | |
| @="Open mintty Here" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| add_filter( 'the_content', 'remove_empty_p', 20, 1 ); | |
| function remove_empty_p( $content ){ | |
| // clean up p tags around block elements | |
| $content = preg_replace( array( | |
| '#<p>\s*<(div|aside|section|article|header|footer)#', | |
| '#</(div|aside|section|article|header|footer)>\s*</p>#', | |
| '#</(div|aside|section|article|header|footer)>\s*<br ?/?>#', | |
| '#<(div|aside|section|article|header|footer)(.*?)>\s*</p>#', | |
| '#<p>\s*</(div|aside|section|article|header|footer)#', |