Skip to content

Instantly share code, notes, and snippets.

View chief10's full-sized avatar
🎯
Focusing

chief10

🎯
Focusing
  • Los Angeles, CA
View GitHub Profile
/* Global Styles */
html,
body {
height: 100%;
width: 100%;
}
.vert-text {
display: table-cell;
{ url: 'https://na.api.pvp.net/api/lol/na/v2.2/match/1783522771',
qs: { api_key: '201c5e3d-51ec-42d3-ad6a-d03e011926d3' } } 429
Unhandled rejection Error: 429
at Object.ensureErrorObject (/Users/Mike-THO/Google Drive/ArenaCodeBase/ArenaOnlineAPI/node_modules/bluebird/js/main/util.js:228:20)
at Promise._rejectCallback (/Users/Mike-THO/Google Drive/ArenaCodeBase/ArenaOnlineAPI/node_modules/bluebird/js/main/promise.js:416:22)
at MappingPromiseArray.PromiseArray.__hardReject__.PromiseArray._reject (/Users/Mike-THO/Google Drive/ArenaCodeBase/ArenaOnlineAPI/node_modules/bluebird/js/main/promise_array.js:109:19)
at MappingPromiseArray.PromiseArray._promiseRejected (/Users/Mike-THO/Google Drive/ArenaCodeBase/ArenaOnlineAPI/node_modules/bluebird/js/main/promise_array.js:130:10)
at Promise._settlePromiseAt (/Users/Mike-THO/Google Drive/ArenaCodeBase/ArenaOnlineAPI/node_modules/bluebird/js/main/promise.js:538:26)
at Promise._settlePromises (/Users/Mike-THO/Google Drive/ArenaCodeBase/ArenaOnline
@chief10
chief10 / 0_reuse_code.js
Last active August 29, 2015 14:22
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
//Function declaration.
function foo() {};
//Function expression.
var foo = function() {};
spyOn(matchProcessor, 'doSomething').and.returnValue('Does your penis itch?');
Getting Block #:0
Hitting Riot API: https://na.api.pvp.net/api/lol/na/v2.2/matchhistory/38999238
Getting Block #:15
Hitting Riot API: https://na.api.pvp.net/api/lol/na/v2.2/matchhistory/38999238
Getting Block #:30
Hitting Riot API: https://na.api.pvp.net/api/lol/na/v2.2/matchhistory/38999238
Getting Block #:45
Hitting Riot API: https://na.api.pvp.net/api/lol/na/v2.2/matchhistory/38999238
Getting Block #:60
Hitting Riot API: https://na.api.pvp.net/api/lol/na/v2.2/matchhistory/38999238
$(document).ready(function() {
var video = $('#ytcontainer');
var videoFrame = '<iframe id="myframe" width="700" height=“360" src="https://www.youtube.com/embed/C9mj2X-m2bU?autoplay=1" frameborder="0" allowfullscreen="" style=" min-height:360px; display: block; "/>';
video.on("click", function() {
video.html(videoFrame);
});
});
if (!empty($description) && $item['link']['depth'] !== '1') {
debug_to_console($description);
debug_to_console($item['link']['link_title']);
debug_to_console($item['link']['depth']);
} else {
//Some other logic.
$output .= l('<span>' . t($item['link']['link_title']) . 'SomeJuice!</span>', $item['link']['link_path'], array('html' => TRUE));
}
angular.module('myApp')
.component('simpleItem', {
template: '<h1>Meeting: {{ $ctrl.getMeetingInfo() }}</h1>',
controller: function() {
this.getMeetingInfo = function() {
return ("Person: " + this.who + ' ' + "At: " + this.where);
}
},
bindings: { who: '<', where: '<'}
angular.module('myApp')
.component('simpleItem', {
template: '<h1>Meeting: {{ $ctrl.getMeetingInfo() }}</h1>',
controller: function() {
this.getMeetingInfo = function() {
return ("Person: " + this.who + ' ' + "At: " + this.where);
}
},