This file contains 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
javascript: | |
__cnt__=0; | |
__buttons__=jQuery(".content-main .user-actions-follow-button"); | |
__length__=__buttons__.length; | |
__interval__=setInterval(function () { | |
el=jQuery(__buttons__[__cnt__]); | |
if (__cnt__ === __length__) { | |
alert("All done!"); | |
clearInterval(__interval__); | |
} |
This file contains 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
[ | |
{ | |
"popularity":3, | |
"translated":true, | |
"adult":false, | |
"language":"en", | |
"original_name":"Annie Hall", | |
"name":"Annie Hall", | |
"alternative_name":"Io e Annie", | |
"movie_type":"movie", |
This file contains 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
@mixin font-stack($family, $weight, $size: inherit, $line-height: inherit, $style: normal, $stack: '"Lucida Grande", "Lucida Sans", Verdana, Helvetica, Arial, sans-serif') { | |
@if $weight >= 6 { -webkit-font-smoothing: antialiased; } // Sharpen up the bold text | |
font: { | |
@if $style == normal { | |
family: "#{$family} #{$weight}r", "#{$family} A", "#{$family} B", unquote($stack); | |
} | |
@else if $style == italic { | |
family: "#{$family} #{$weight}i", "#{$family} A", "#{$family} B", unquote($stack); | |
} | |
size: $size; |
This file contains 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
import React, {Component, PropTypes} from 'react'; | |
import Hammer from 'react-hammerjs'; | |
import classNames from 'classnames'; | |
export default class ScrollPanel extends Component { | |
static propTypes = { | |
items: PropTypes.array, | |
menuStyle: PropTypes.string, | |
selectedItem: PropTypes.number, |
This file contains 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
javascript: | |
__cnt__=0; | |
__sep__=""; | |
__username__=jQuery('.content-main .account-group'); | |
__length__=__username__.length; | |
__usernames__=''; | |
__interval__=setInterval(function () { | |
el=jQuery(__username__[__cnt__]); | |
if (__cnt__ === __length__) { | |
div = $('<div></div>'); |
This file contains 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
import React, { Component } from 'react'; | |
import update from 'react-addons-update'; | |
export default class App extends Component { | |
state = { | |
touches: { | |
touchstart: { | |
x: -1, | |
y: -1 |
This file contains 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
// Use Gists to store code you would like to remember later on | |
console.log(window); // log the "window" object to the console |
This file contains 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
// To use with your component as a decorator: | |
import React from 'react'; | |
import styles from './styles.css'; | |
import Internalize from 'components/InternalLinks'; | |
@Internalize | |
export default class BlogContent extends React.Component { | |
static propTypes = { | |
content: PropTypes.static.isRequired |
This file contains 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
/* CSS */ | |
.Chapters { | |
column-count: 2; | |
counter-reset: toc -1; | |
} | |
.Chapter { | |
counter-increment: toc; | |
list-style-type: none; |
This file contains 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
Show hidden characters
// Convert 2 spaces to tabs in Sublime Text | |
// To add a key binding, go to "Sublime Text » Preferences » Key Bindings - User" and add the following line: | |
// { "keys": ["super+;"], "command": "run_macro_file", "args": {"file": "Packages/User/convert_spaces_to_tabs.sublime-macro"} } | |
// Change the `super+;` shortcut accordingly. | |
[ | |
{ | |
"args": { | |
"setting": "tab_size", | |
"value": 2 |
OlderNewer