Note: this rough draft has turned into https://github.com/maxogden/art-of-node#art-of-node
go to https://github.com/maxogden/art-of-node#art-of-node to view the newer versions of this document
# The following is a quick and dirty example of uploading to vimeo using ruby | |
# It assumes that you already have an access token for a user | |
require 'net/http' | |
require 'httparty' | |
ACCESS_TOKEN = "your access token here" | |
auth = "Bearer #{ACCESS_TOKEN}" | |
# get ticket |
// I crack myself up. | |
// Typed this to coworkers in team chat: | |
person.eat(food, function() { | |
if (typeof food === 'chipotle') { | |
// Yum! | |
setTimeout(function() { | |
// Oh noes! | |
// http://www.hulu.com/watch/10304/saturday-night-live-colon-blow |
/*------------------------------------*\ | |
$NAV | |
\*------------------------------------*/ | |
/* | |
TAGS: ^lists ^navigation ^text | |
*/ | |
/* | |
As per csswizardry.com/2011/09/the-nav-abstraction | |
*/ | |
.nav{ |
go to https://github.com/maxogden/art-of-node#art-of-node to view the newer versions of this document
# Serve & Export commands | |
alias client_site='cd ~/projects/client-site && serve' | |
alias client_site_html='cd ~/projects && rm -rf client-site-html && cd ~/projects/client-site && serve export ../client-site-html && cd ~/projects/client-site-html && zip -r templates.zip ./* && open index.html' |
# Used to cache-bust <html manifest="..."> locally | |
def manifest_time | |
t = Time.now | |
year = t.year | |
month = t.month | |
day = t.day | |
hour = t.hour | |
min = t.min | |
# Seconds changes too frequently for |
Installation Steps | |
PART 1: INSTALLING & CONFIGURING APACHE, MYSQL, & PHP ON WINDOWS (WAMP) | |
---------------------------------------------------------------------------------- | |
1. Download WampServer from http://www.wampserver.com/en/ & install. | |
C:\wamp is a good location. Do not run WampServer yet. | |
2. Configure MySQL. The default MySQL configuration file is very limiting. Choose one | |
of the model config files that best suits your system and copy & paste it to "wampserver.conf". |
Note that this is very purpose-built. The job args in particular depend on a unique key being in the first position.
There is also plenty of brittle code all over the place.
Instead, use this as a guide for how you might build your own. A lot of the parts are the same between implementations.
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8"> | |
<title>Media Query Multiple Columns</title> | |
<meta name="viewport" content="width=device-width, intial-scale=1"> | |
<style> | |
@media all and (min-width: 40em) and (min-height: 36em) { | |
[role="main"] { | |
-webkit-column-count: 2; |
/*global define: false, window: false */ | |
define(['jquery'], function ($) { | |
'use strict'; | |
return function () { | |
/* Begin monkey-patch Tap event support into $ */ | |
var x = 0, | |
y = 0, | |
threshold = 40, | |
// Sometimes there is lag between the last update and touchend. |