Skip to content

Instantly share code, notes, and snippets.

View kylebradshaw's full-sized avatar
🍌

Kyle Bradshaw kylebradshaw

🍌
View GitHub Profile

Sublime Text 2 - Useful Shortcuts

Tested in Mac OS X: super == command

Open/Goto


  • super+t: go to file
  • super+ctrl+p: go to project
  • super+r: go to methods
@kylebradshaw
kylebradshaw / .gitconfig
Created November 16, 2014 00:48
gitconfig
[core]
editor = subl
autocrlf = input
safecrlf = true
[color]
diff = auto
status = auto
branch = auto
Provider Singleton Instantiable Configurable
Constant Yes No No
Value Yes No No
Service Yes No No
Factory Yes Yes No
Decorator Yes No? No
Provider Yes Yes Yes

Constant

@kylebradshaw
kylebradshaw / README.md
Last active August 29, 2015 14:22 — forked from kerryrodden/.block

This example shows how it is possible to use a D3 sunburst visualization (partition layout) with data that describes sequences of events.

A good use case is to summarize navigation paths through a web site, as in the sample synthetic data file (visit_sequences.csv). The visualization makes it easy to understand visits that start directly on a product page (e.g. after landing there from a search engine), compared to visits where users arrive on the site's home page and navigate from there. Where a funnel lets you understand a single pre-selected path, this allows you to see all possible paths.

Features:

  • works with data that is in a CSV format (you don't need to pre-generate a hierarchical JSON file, unless your data file is very large)
  • interactive breadcrumb trail helps to emphasize the sequence, so that it is easy for a first-time user to understand what they are seeing
  • percentages are shown explicitly, to help overcome the distortion of the data that occurs wh
'use strict';
var gulp = require('gulp');
var gutil = require('gulp-util');
var del = require('del');
var uglify = require('gulp-uglify');
var gulpif = require('gulp-if');
var exec = require('child_process').exec;
var notify = require('gulp-notify');
'use strict';
// Generated on 2014-04-14 using generator-leaflet 0.0.14
var gulp = require('gulp');
var open = require('open');
var wiredep = require('wiredep').stream;
// Load plugins
var $ = require('gulp-load-plugins')();
@kylebradshaw
kylebradshaw / angular-directives.md
Last active August 29, 2015 14:26 — forked from mikesigs/angular-directive-priority.md
Angular.js directives sorted by priority
Directive Priority Terminal Creates new scope Can be used as multiElement
ngSwitch 1200 X
ngNonBindable 1000 X
ngRepeat 1000 X X X
ngIf 600 X X X
ngController 500 X
ngInit 450
ngInclude 400 X X
ngView 400 X
ROBOHYDRA PLUGIN CODE:
...
new RoboHydraHead({
path: '/services/users',
handler: function(req, res) {
if (req.method === 'POST') {
var newUser;
var rand = Math.floor(Math.random() * (1000 - 100)) + 100;
for (var i in req.bodyParams) {
@kylebradshaw
kylebradshaw / responsinator-bookmarklet
Created March 15, 2012 14:53
The Responsinator Bookmarklet
javascript:void(function(){window.location='http://responsinator.com/%3Furl='+encodeURIComponent(window.location.href);})();