Skip to content

Instantly share code, notes, and snippets.

Eric ek

Block or report user

Report or block ek

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View SketchSystems.spec
Initialize flow -> Step 1
Step Flow
Cancel -> Entry
Step 1*
Next -> Step 2
Step 2
Next -> Step 3
Step 3
ek / regex-match-all-css-html-color-keywords.txt
Created Sep 27, 2018
Regex to match all CSS / HTML color keywords / names
View regex-match-all-css-html-color-keywords.txt
(?:^|(?<= ))(AliceBlue|AntiqueWhite|Aqua|Aquamarine|Azure|Beige|Bisque|Black|BlanchedAlmond|Blue|BlueViolet|Brown|BurlyWood|CadetBlue|Chartreuse|Chocolate|Coral|CornflowerBlue|Cornsilk|Crimson|Cyan|DarkBlue|DarkCyan|DarkGoldenRod|DarkGray|DarkGrey|DarkGreen|DarkKhaki|DarkMagenta|DarkOliveGreen|DarkOrange|DarkOrchid|DarkRed|DarkSalmon|DarkSeaGreen|DarkSlateBlue|DarkSlateGray|DarkSlateGrey|DarkTurquoise|DarkViolet|DeepPink|DeepSkyBlue|DimGray|DimGrey|DodgerBlue|FireBrick|FloralWhite|ForestGreen|Fuchsia|Gainsboro|GhostWhite|Gold|GoldenRod|Gray|Grey|Green|GreenYellow|HoneyDew|HotPink|IndianRed|Indigo|Ivory|Khaki|Lavender|LavenderBlush|LawnGreen|LemonChiffon|LightBlue|LightCoral|LightCyan|LightGoldenRodYellow|LightGray|LightGrey|LightGreen|LightPink|LightSalmon|LightSeaGreen|LightSkyBlue|LightSlateGray|LightSlateGrey|LightSteelBlue|LightYellow|Lime|LimeGreen|Linen|Magenta|Maroon|MediumAquaMarine|MediumBlue|MediumOrchid|MediumPurple|MediumSeaGreen|MediumSlateBlue|MediumSpringGreen|MediumTurquoise|MediumVioletRed|Mi
ek / html-color-names-keywords-list.txt
Created Sep 27, 2018
HTML / CSS Color Names / Keywords list
View html-color-names-keywords-list.txt
ek / output
Created Jul 20, 2018
yarn upgrade output
View output
➜ promotions-personalized-offers-ui git:(master) yarn upgrade @appfabric/plugin-build@3.11.2
yarn upgrade v1.7.0
[1/4] 🔍 Resolving packages...
warning @appfabric/plugin-build > babel-preset-es2015@6.24.1: 🙌 Thanks for using Babel: we recommend using babel-preset-env now: please read to update!
warning @appfabric/plugin-build > babel-relay-plugin@0.8.1: Replaced by the new babel-plugin-relay
[2/4] 🚚 Fetching packages...
[3/4] 🔗 Linking dependencies...
warning "@cg/partnerplatform-web-shared > uglifyjs-webpack-plugin@1.2.5" has unmet peer dependency "webpack@^2.0.0 || ^3.0.0 || ^4.0.0".
warning "@cg/partnerplatform-web-shared > uglifyjs-webpack-plugin > schema-utils@0.4.5" has unmet peer dependency "webpack@^2.0.0 || ^3.0.0 || ^4.0.0".
warning " > react-modal@3.3.2" has unmet peer dependency "react@^0.14.0 || ^15.0.0 || ^16".
ek /
Last active Jan 17, 2018
Process to compute opportunity scores for Jobs to be Done survey analysis

Process to compute opportunity scores for Jobs to be Done survey analysis


  • Given an array of outcomes.
  • Given an array of responses to a survey on importance and satisfaction ratings for each of the outcomes.
  • Given the response ratings are 1-5.
  • IMP = 10 x % Very or Extremely important
  • SAT = 10 x % Very or Extremely satisfied
  • OPP = IMP + MAX (IMP-SAT, 0)
  • Values of 4 or 5 are considered Very or Extremely important / satisfied
ek / build-to-grow-no-silver-bullet-snip.txt
Created Aug 9, 2016
Brooks suggesting a move from "build" to "grow" as the key metaphor in software development
View build-to-grow-no-silver-bullet-snip.txt
In "No Silver Bullet" [1] Brooks wrote in 1986:
"I still remember the jolt I felt in 1958 when I first heard a friend talk about building a program,
as opposed to writing one. In a flash he broadened my whole view of the software process. The
metaphor shift was powerful, and accurate. Today we understand how like other building processes the
construction of software is, and we freely use other elements of the metaphor, such as
specifications, assembly of components, and scaffolding."
"The building metaphor has outlived its usefulness. It is time to change again. If, as I believe,
the conceptual structures we construct today are too complicated to be specified accurately in
ek / extract-query-string-variable.js
Created Mar 12, 2016
Extract a variable from window.location query string
View extract-query-string-variable.js
function getQueryVariable(variable) {
var query =;
var vars = query.split("&");
for (var i=0;i<vars.length;i++) {
var pair = vars[i].split("=");
if(pair[0] == variable){return pair[1];}
ek / generateUniqueId.js
Created Jan 19, 2016
generate a unique UUID using Javascript Math.random
View generateUniqueId.js
// from alexmorleyfinch's comment on this thread:
var generateUniqueId = function(){
function chr4(){
return Math.random().toString(16).slice(-4);
return chr4() + chr4() +
'-' + chr4() +
'-' + chr4() +
'-' + chr4() +
ek /
Last active Aug 29, 2015
Animation code for L1 Outerwear 2008 Flash site
// help the book get centered...
_root.bookOffsetX = 220;
_root.bookOffsetY = 400;
// this function runs every time the window is resized.
var resizeFunction = function() {
// find the scale for book_mc
stagewidth = Stage.width;
stageheight = Stage.height;
ek /
Created Aug 11, 2015 - Actionscript 3 - Animation code for Edgemoor
package wolken.edgemoor {
import flash.display.MovieClip;
import flash.text.TextField;
import flash.text.TextFormat;
import fl.transitions.Tween;
import fl.transitions.TweenEvent;
You can’t perform that action at this time.