View gist:1fb0709bb03e8d5bae25
1 2 3 4 5 6 7 8 9 10
function matchesSelector(el, selectorText, ctx) {
var all = (ctx||el.ownerDocument).querySelectorAll(selectorText);
return indexOf(all, el) != -1;
}
 
function findAncestor(el, selectorText, container) {
if(el == null || el === container)
return null;
var parent = el.parentNode;
View Prototype Inheritance
1 2 3 4 5 6 7
function Car(make) {
this.make = make;
}
 
Car.prototype.drive = function() {
console.log('driving ' + this.make);
};
View bind
1 2 3 4 5 6
var couple = { m : "Garrett", f : "Tomomi" };
var marriage = function() { console.log(this.f + " is married to " + this.m); };
var status = marriage.bind(couple);
status();
 
"Tomomi is married to Garrett";
View Resume
1 2 3 4 5 6 7 8 9 10
Garrett Smith
San Francisco, CA 94103
(415) 606-3980
 
 
Skills:
JavaScript, HTML, CSS.
XP, OOAD, Refactoring, JavaScript Library Abatement, Mentoring.
 
Experience:
View tco no
1 2 3 4 5 6 7 8 9 10
document.addEventListener("mouseover", function(e) {
var t=e.target, u;
if(!t.href) t = t.parentNode;
if(t.href) {
if(t.host=="t.co"){
u=t.getAttribute("data-expanded-url");
if(!u && t.search) {
u=(u=t.search.match(/\burl=(.+)?&/))&&unescape(u[1]);
} else if(!u && t.title.indexOf("http") == 0) {
u = t.title;
View usurp-tco.js
1 2 3 4 5 6 7 8 9 10
function tcoToLinkTitleURL(ev) {
var target = ev.target;
if(/^(http(?:s?):)?\/\/t.co\//.test(target.href) && /^(http(?:s?):)?\/\//.test(target.title)) {
target.href = target.title;
}
}
 
if(location.hostname == "twitter.com") {
document.addEventListener("mousedown", tcoToLinkTitleURL, true);
}
View ndaa-flyer
1 2 3 4 5 6 7 8 9
[FRONT]
NDAA - Indefinite Detention with no trial.
[/FRONT]
 
[BACK]
NDAA of 2012
Indefinite Detention with no trial. On Dec 2011, Congress and President Obama passed NDAA 2012. NDAA goes against most of the bill of rights, habeas corpus, and posse comitatus.
 
Taxpayer Cost: $622 billion
View police-state
1 2 3 4 5 6 7 8 9 10
Google:
NDAA - Indefinite Detention with no trial. $662 billion defense spending
HR 645 - "National Emergency Centers Establishment Act"
Internment / Resettlement Specialist (31E)
SOPA - Internet Censorship Bill
Civilian Inmate Labor Program
National Quick Response Team
Enemy Expatriation Act
USA PATRIOT
TSA
View deploy fail 2
1 2 3 4 5 6 7 8 9 10
Garrett-Smiths-MacBook-Pro:missionmassage garrettsmith$ jitsu deploy
 
info: Welcome to Nodejitsu
info: It worked if it ends with Nodejitsu ok
info: Executing command deploy
info: Authenticated as xkit
warn:
warn: Your package.json file is missing required fields:
warn:
warn: subdomain
Something went wrong with that request. Please try again.