This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var type = function (isArray, type){ | |
| return function(object) { | |
| type = typeof object; | |
| return type === "object" ? ( | |
| object ? ( | |
| isArray(object) ? "array" : type | |
| ) : "null" | |
| ) : type; | |
| }; | |
| }(Array.isArray || function(Array, toString, array){ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * so here the thing ... you go in your github page | |
| * as example I go here: https://github.com/WebReflection | |
| * you open your console | |
| * you copy and paste this shit | |
| * then you write and execute in the console | |
| * write("Hi There!"); | |
| * NOTE: Pixel Font from a 2006 project of mine :-) http://devpro.it/pixelfont/ | |
| */ | |
| function write(text, color, start) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var a, b; // JUST LOL JSLINT ! | |
| // tell me how less confusing this is ^_^ | |
| // a can do async stuff | |
| // then b is needed | |
| function a() { | |
| setTimeout(b, 1); | |
| } | |
| // b can be used regardless a() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Ubuntu 12.10 via VirtualBox Image | |
| # go in the user dir | |
| cd ~/ | |
| # install git CL tool and g++ | |
| sudo apt-get install git | |
| sudo apt-get install g++ | |
| # clone node.js git repo |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 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 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # these info are valid today | |
| # 4th March 2013 | |
| # flush latest Arch for Pi dist | |
| # via dd or other ways | |
| # With A DHCPed Network Cable | |
| pacman -Syu | |
| sync | |
| reboot |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // WebReflection quick and dirty polyfill | |
| (function(AP){ | |
| if ('find' in AP) return; | |
| // quick size/safe version | |
| // if predicate is not a function, call will throw | |
| // if this is not array like, throws or nothing happens | |
| function find(value) { | |
| return function (predicate, thisArg) { | |
| for(var | |
| k = 0, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var Symbol; | |
| if (!Symbol) { | |
| Symbol = (function(Object){ | |
| var defineProperty = Object.defineProperty, | |
| prefix = '__simbol' + Math.random() + '__', | |
| id = 0; | |
| function Symbol() { | |
| var self = this; | |
| defineProperty( | |
| Object.prototype, |
Non greedy in 95 bytes
(function(O,P){P in O||(O[P]=function(o,p){o.__proto__=p;return o})})(Object,'setPrototypeOf');
Or via self reassignment in 91 bytes
(function(O,P){O[P]=O[P]||function(o,p){o.__proto__=p;return o}})(Object,"setPrototypeOf");
Or direct call, 65 bytes, for you closure!
var p=Object.setPrototypeOf||function(o,p){o.__proto__=p;return o};