Skip to content

Instantly share code, notes, and snippets.

@deminew
deminew / mobile tags for your '<head>'
Created September 1, 2011 03:00 — forked from chuanxshi/mobile tags for your '<head>'
mobile tags for your '<head>'
<!doctype html>
<!-- Helpful things to keep in your <head/>
// Shi Chuan, https://github.com/shichuan/mobile-html5-boilerplate
-->
<head>
<!-- consider using below meta tags if you want to disable format detection by default -->
<meta name="format-detection" content="telephone=no"/>
<meta name="format-detection" content="address=no"/>
<!-- consider using below link tag if the page is duplicate content of a desktop version -->
@deminew
deminew / gist:1086076
Created July 16, 2011 06:32 — forked from kosso/gist:1059705
Google PlusBar..
/*
The code for the bookmarklet:
You create bookmarklets with a href javascript: links.
If you don't know how to do this, simply copy/paste one you might already have in your toolbar and
then edit the url properies with this long line below:
*/
javascript:(function(){var%20included%20=%20false,openbar%20=%20false,src%20=%20"http://YOUR_DOMAIN/YOUR_SCRIPT.JS";var%20isIncluded%20=%20(function(){var%20scripts%20=%20document.getElementsByTagName('script');for(var%20i=0;i<scripts.length;i++){if(scripts[i].src%20==%20src){bar_toggle();%20return%20true;}}return%20false;})();if(isIncluded){%20%20}else{if(included){return%20false;}included%20=%20true;var%20head%20=%20document.getElementsByTagName("head")[0]%20||%20document.documentElement,script%20=%20document.createElement("script");script.type%20=%20"text/javascript";script.async%20=%20true;script.src%20=%20src;head.insertBefore(%20script,%20head.firstChild%20);}})();
@deminew
deminew / README.md
Created May 28, 2011 22:03 — forked from bergie/README.md
Falsy Values tutorials
@deminew
deminew / LICENSE.txt
Created May 28, 2011 01:08 — forked from 140bytes/LICENSE.txt
140byt.es -- Click ↑↑ fork ↑↑ to play!
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2011 YOUR_NAME_HERE <YOUR_URL_HERE>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
@deminew
deminew / utmstrip.user.js
Created May 25, 2011 15:30 — forked from paulirish/utmstrip.user.js
userscript: Drop the UTM params from a URL when the page loads
// ==UserScript==
// @name UTM param stripper
// @author Paul Irish
// @namespace http://github.com/paulirish
// @version 1.1
// @description Drop the UTM params from a URL when the page loads.
// @extra Cuz you know they're all ugly n shit.
// @include http://*
// ==/UserScript==
@deminew
deminew / nodeconf_2011.md
Created May 12, 2011 07:46 — forked from guybrush/nodeconf_2011.md
a list of slides from nodeconf 2011
@deminew
deminew / alphabet.js
Created May 9, 2011 05:51 — forked from mheadd/alphabet.js
A collection of code samples used in a talk at JSConf 2011
// A simple JavaScript app that runs on Tropo.
var letters = 'abcdefghijklmnopqrstuvwxyz';
var letterArray = letters.split('');
var start = new Date();
say('Hello, and welcome to Tropo.');
for(var i = 0; i < letterArray.length; i++) {
say(letterArray[i] + '.');
.mouse, #preview{
position: absolute;
background-repeat: no-repeat;
height: 22px;
min-width: 15px;
z-index: 100;
}
.mouse{
background-image: url('../images/cursor.png');
var r1 = 0;
var ycenter = 0;
var xcenter = 0;
var cameraX = 0;
var cameraY = 0;
var cameraZ = 0;
var cop = 500;
var pta = [];
var quats = [];
var points = [];
@deminew
deminew / module.js
Created April 28, 2011 17:04 — forked from creationix/module.js
A super simple module system for browsers. Assumes all source files are concatenated and in browser.
function define(name, fn) {
if (!defs) { defs = {}; }
defs[name] = fn;
}
function require(name) {
console.log("Loading " + name);
if (modules && modules.hasOwnProperty(name)) return modules[name];
if (defs && defs.hasOwnProperty(name)) {
if (!modules) { modules = {}; }
var fn = defs[name];