Skip to content

Instantly share code, notes, and snippets.

View rexagod's full-sized avatar
💭
I may be slow to respond.

Pranshu Srivastava rexagod

💭
I may be slow to respond.
View GitHub Profile
@rexagod
rexagod / corners
Created June 17, 2019 19:35
command output for `matcher corners`
[ { x: 37, y: 261 },
{ x: 482, y: 402 },
{ x: 84, y: 331 },
{ x: 38, y: 293 },
{ x: 39, y: 246 },
{ x: 36, y: 251 },
{ x: 604, y: 382 },
{ x: 78, y: 457 },
{ x: 572, y: 264 },
{ x: 337, y: 367 },
@rexagod
rexagod / matches
Created June 17, 2019 19:34
command output for `matcher matches`
[ { confidence: { c1: 63, c2: 187 },
x1: 359,
y1: 48,
x2: 65,
y2: 309,
population: 9 },
{ confidence: { c1: 124, c2: 169 },
x1: 260,
y1: 333,
x2: 546,
@rexagod
rexagod / nvm.md
Created May 5, 2019 07:28
Node Version Manager

Node Version Manager

Note: refers to any version-like string nvm understands. This includes:

  • full or partial version numbers, starting with an optional "v" (0.10, v0.1.2, v1)
  • default (built-in) aliases: node, stable, unstable, iojs, system
  • custom aliases you define with nvm alias foo

Any options that produce colorized output should respect the --no-colors option.

Usage:

@rexagod
rexagod / emoji.json
Last active March 9, 2022 06:20
PublicLab.Editor's reference collection of emojis
{
"+1": "👍",
"-1": "👎",
"smiley": "😃",
"laughing": "😆",
"confused": "😕",
"heart": "❤️",
"tada": "🎉",
"clap": "👏",
"sweat_smile": "😅",
@rexagod
rexagod / resig-class-intro.js
Last active March 9, 2022 06:20
Intro to John Resig's Class inheritance in JavaScript
var Person = Class.extend({
init: function(isDancing){
this.dancing = isDancing;
},
dance: function(){
return this.dancing;
}
});
var Ninja = Person.extend({
@rexagod
rexagod / resig-class-implementation.js
Last active March 9, 2022 06:20
Simple JavaScript inheritance implemented using John Resig's Class
/* Simple JavaScript Inheritance
* By John Resig https://johnresig.com/
* MIT Licensed.
*/
// Inspired by base2 and Prototype
(function(){
var initializing = false, fnTest = /xyz/.test(function(){xyz;}) ? /\b_super\b/ : /.*/;
// The base Class implementation (does nothing)
this.Class = function(){};