Skip to content

Instantly share code, notes, and snippets.

🍐
Working on a relaunch.

Charlie Park charliepark

🍐
Working on a relaunch.
Block or report user

Report or block charliepark

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View quickBrownFox
function test(candidate){
return candidate === passing;
}
var sentence = "The quick brown fox jumps.";
var passing = "Jumps fox brown quick the.";
function turnaround(sentence){
sentence = sentence.toLowerCase().replace('.','').split(' ');
sentence = sentence.reverse().join(' ')+".";
View test_faq.js
[
[
"Who taught you to do this stuff?",
"You, alright? I learned it by watching you!"
],
[
"Who in the world am I?",
"Ah, that's the great puzzle."
],
View template.html
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title></title>
</head>
<body>
View gzip_questions.md

When GZIPped, is this …

h1 {
  font-size: 3em;
  font-weight: bold;
}

h2 {
  font-size: 2em;
@charliepark
charliepark / screenshot.js
Created Jun 5, 2014
A demo Phantom.js script
View screenshot.js
var width = 320;
var height = 480;
var webpage = require('webpage');
page = webpage.create();
page.viewportSize = {width: width, height: height};
page.open('https://ifttt.com', function(status) {
console.log(status);
page.evaluate(function(w, h) {
document.body.style.width = w + "px";
View fit.html
<!DOCTYPE html>
<html>
<head>
<style type="text/css">
div{background:#eee;margin:10px;width:350px;border:20px solid #ccc;padding:10px}
p{font-family:courier;margin:0;padding:0;}
</style>
</head>
<body>
<div style="height:180px;"><p class="js-fit">This is some text to resize.</p></div>
View box-sizing without the asterisk
nav,
main,
section,
article,
aside,
header,
footer,
div,
details,
summary,
View performantRetina.js
var performantRetina = {
run : function(){
if(!window.devicePixelRatio || window.devicePixelRatio === 1){return;}
var images = document.getElementsByTagName('img');
for(var i = 0; i < images.length; i++){
var retinaSrc = images[i].getAttribute('data-retina-src');
if(!retinaSrc){continue;}
images[i].setAttribute('src', retinaSrc);
}
}
View Doing.js
{
"When you open your computer" : [
"turn off deeplink test",
"turn off wtf / recipes test"
]
}
@charliepark
charliepark / mountain_goats_new_songs.md
Last active Aug 29, 2015
Recordings when John / TMG introduced now-classic songs
View mountain_goats_new_songs.md
Song Title Date Venue City Link Show Page
Attention All Pickpockets 2007-06-17 Farm Sanctuary Watkins Glen, NY https://archive.org/details/tmg2007-06-17.flac
Cry for Judas 2012-10-13 Music Hall of Williamsburg Brooklyn, NY https://archive.org/download/MountainGoats2012-10-13.nyctaper/MountainGoats2012-10-13_nyctaper_t23.mp3 https://archive.org/details/MountainGoats2012-10-13.nyctaper
Dance Music 2004-05-26 Bottom of the Hill San Francisco, CA https://archive.org/details/tmg2004-05-26.flacf
Dilaudid 2004-10-04 The Magic Stick Detroit, MI https://archive.org/download/tmg2004-10-04.aud.320mp3/tmg2004-10-04t06.mp3 https://archive.org/details/tmg2004-10-04.aud.320mp3
Going to Georgia 1995-01-15 The Chameleon San Francisco, CA https://archive.org/download/tmg1995-01-15.aud.192mp3/tmg1995-01-15t11.mp3
Going to Maine 2004-10-11 The Black Cat Washington, DC https://archive.org/download/tmg2004-10-11.aud.128mp3/tmg2004-10-11t09.mp3 https://archive.org/details/
You can’t perform that action at this time.