Skip to content

Instantly share code, notes, and snippets.

View mysterycommand's full-sized avatar

Matt Hayes mysterycommand

View GitHub Profile
@mysterycommand
mysterycommand / ecs.ts
Last active August 27, 2019 18:29
Some ideas
/**
* 0.0
*/
// const [factory, system] = createComponent();
/**
* 0.1
*/
// const [activate, update, deactivate] = createComponent(data, system, scheduler);
Verifying my Blockstack ID is secured with the address 1Gc7ck31j5BdEz9PUniXNG3A2uGHGABY9P https://explorer.blockstack.org/address/1Gc7ck31j5BdEz9PUniXNG3A2uGHGABY9P
@mysterycommand
mysterycommand / from-scratch.md
Created September 8, 2018 19:16
Common Git Workflow

From scratch

Setting up

I'll assume we're starting from nothing, so the first thing we'll need to do is clone the repo … but where to put it? I like to organize files on my local machine in a way that's similar to how GitHub does it. Locally I'll put everything in a "Sites" folder in my home directory. The short hand way of refering to this in Terminal is ~/Sites/ (~/ is an alias for /Users/<your user name>/), so the full path to your sites folder is /Users/<your user name>/Sites/.

To keep with the theme of "local machine organized like GitHub", we'll start by making a directory for the organization or owner of the repo we're going to clone. This is the first part of a GitHub URL which have the form of https://github.com/<organization or owner>/<repo name>, so:

# mkdir is short for "make directory"

Keybase proof

I hereby claim:

  • I am mysterycommand on github.
  • I am mysterycommand (https://keybase.io/mysterycommand) on keybase.
  • I have a public key ASAiNo06uFlihzwNVUVfBNz6KKYqUTklF-hXZhQdo3H2Xgo

To claim this, I am signing this object:

@mysterycommand
mysterycommand / what-forces-layout.md
Created September 23, 2015 15:52 — forked from paulirish/what-forces-layout.md
What forces layout/reflow. The comprehensive list.

What forces layout / reflow

All of the below properties or methods, when requested/called in JavaScript, will trigger the browser to synchronously calculate the style and layout. This is also called reflow or layout thrashing, and is common performance bottleneck.

Element

Box metrics
  • elem.offsetLeft, elem.offsetTop, elem.offsetWidth, elem.offsetHeight, elem.offsetParent
  • elem.clientLeft, elem.clientTop, elem.clientWidth, elem.clientHeight
  • elem.getClientRects(), elem.getBoundingClientRect()
@mysterycommand
mysterycommand / stack-careers-error-140214
Created February 14, 2014 22:12
The StackOverflow Careers 2.0 Error Message I Get
SyntaxError: Unexpected token 
at Object.parse (native)
at U (http://cdn-careers.sstatic.net/careers/Js/third-party/angular/1.2.6/angular.min.js?v=2910c9fc42a7:1:4691)
at Vt.o.defaults.transformResponse (http://cdn-careers.sstatic.net/careers/Js/third-party/angular/1.2.6/angular.min.js?v=2910c9fc42a7:2:778)
at http://cdn-careers.sstatic.net/careers/Js/third-party/angular/1.2.6/angular.min.js?v=2910c9fc42a7:2:502
at Array.forEach (native)
at a (http://cdn-careers.sstatic.net/careers/Js/third-party/angular/1.2.6/angular.min.js?v=2910c9fc42a7:1:1004)
at Yt (http://cdn-careers.sstatic.net/careers/Js/third-party/angular/1.2.6/angular.min.js?v=2910c9fc42a7:2:510)
at r (http://cdn-careers.sstatic.net/careers/Js/third-party/angular/1.2.6/angular.min.js?v=2910c9fc42a7:2:1195)
at l (http://cdn-careers.sstatic.net/careers/Js/third-party/angular/1.2.6/angular.min.js?v=2910c9fc42a7:2:16273)