View ViewTest.js
var view = new View(); | |
view.width = 1024; | |
view.height = 768; | |
view.render(); |
View gist:5340e780cc7cb667e070999bef47cf58
Verifying my Blockstack ID is secured with the address 1KfdWMJuVKdLB2eCLXNxnkmU1TmdzC9rfM https://explorer.blockstack.org/address/1KfdWMJuVKdLB2eCLXNxnkmU1TmdzC9rfM |
View 779244.html
<html> | |
<head> | |
<title>We need a way to wrap console.log and preserve the file and line number</title> | |
<script> | |
function customLog() { | |
var processedArguments = arguments; | |
// Do something with the arguments besides logging them, maybe format them or store them | |
// ... | |
// Send the output to Developer Tools |
View gist:856492387755f34800759bef2661355f
implement = function(classToReceiveImplementation, classToImplement) { | |
for(var classToImplementProperty in classToImplement) { | |
if(classToReceiveImplementation[classToImplementProperty] === undefined) { | |
//console.log(classToImplementProperty, 'does not exist on class, copying'); | |
classToReceiveImplementation[classToImplementProperty] = cloneProperty(classToImplement[classToImplementProperty]); | |
} | |
} | |
for(var classToImplementPrototypeProperty in classToImplement.prototype) { | |
if(classToReceiveImplementation.prototype[classToImplementPrototypeProperty] === undefined) { |
View overscroll.html
<html> | |
<head> | |
<title>Overscrolling HTML Elements in Chromium on OS X using a Trackpad</title> | |
<style> | |
html { | |
font-family: sans-serif; | |
border: 4px solid #00AAFF; | |
} | |
</style> | |
</head> |
View game.html
<html> | |
<head> | |
<style> | |
@-webkit-keyframes struck { | |
0% { -webkit-transform: translateX(10px); } | |
50% { -webkit-transform: translateX(0); } | |
100% { -webkit-transform: translateX(10px); } |
View CopyAsanaTasks.php
<?php | |
function asanaRequest($methodPath, $httpMethod = 'GET', $body = null) { | |
$apiKey = 'ASANA_API_KEY_HERE'; /// Get it from http://app.asana.com/-/account_api | |
$url = "https://app.asana.com/api/1.0/$methodPath"; | |
$ch = curl_init(); | |
curl_setopt($ch, CURLOPT_URL, $url); | |
curl_setopt($ch, CURLOPT_HTTPAUTH, CURLAUTH_BASIC ) ; | |
curl_setopt($ch, CURLOPT_USERPWD, $apiKey); | |
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); |
View gist:5596828
String.prototype.baconify = function() { | |
return this.replace(/({|})/gi, 'BACON'); | |
} | |
'{"jsonKey":"jsonValue"}'.baconify(); | |
//"BACON"jsonKey":"jsonValue"BACON" |
View gist:5208767
require('node.io').scrape(function() { | |
this.getHtml('http://www.reddit.com/', function(err, $) { | |
var stories = []; | |
$('.entry .title').each(function(title) { | |
stories.push(title.text); | |
}); | |
this.emit(stories); | |
}); | |
}); |
View gist:3739383
*Directions to Kincaid’s* | |
60 Bay View Place | |
Burlingame, CA 94010 | |
From the South: | |
Take Highway 101 North | |
Take the Anza Blvd. exit | |
Turn right onto Airport Blvd. | |
Turn left onto Bay View Place |
NewerOlder