Skip to content

Instantly share code, notes, and snippets.

View iampeterbanjo's full-sized avatar
💭
Error24: not enough hours in the day

Peter Banjo iampeterbanjo

💭
Error24: not enough hours in the day
View GitHub Profile
@iampeterbanjo
iampeterbanjo / snap-svg-animation.js
Created January 27, 2015 07:02
Animating SVG paths using Snap SVG
function revealPath (path, options) {
var revealedAttributes = {'stroke-dashoffset': 0}
, options = options || {}
, easing = mina[options.ease] || mina.easein
, duration = options.duration || 1000
path.animate(revealedAttributes, duration, easing, options.afterRevealPath)
}
function getHiddenAttributes (path) {
@iampeterbanjo
iampeterbanjo / gulpfile.js
Last active August 29, 2015 14:20
Email testing with gulp-litmus and friends
var gulp = require('gulp')
, litmus = require('gulp-litmus')
, gutil = require('gulp-util')
, ftp = require('gulp-ftp')
, inlineCss = require('gulp-inline-css')
, replace = require('gulp-replace')
, runSequence = require('run-sequence')
, config = require('./config.json')
;
@iampeterbanjo
iampeterbanjo / config.toml
Created May 7, 2015 16:24
gohugo.io sample config
archetypedir = "archetype"
# hostname (and path) to the root eg. http=//spf13.com/
baseurl = ""
# include content marked as draft
buildDrafts = false
# include content with datePublished in the future
buildFuture = false
canonifyUrls = false
# config file (default is path/config.yaml|json|toml)
config = "config.toml"
@iampeterbanjo
iampeterbanjo / numberSort.js
Last active August 29, 2015 14:21
Number sort for dynatable.js (www.dynatable.com)
// sort numberAges for the dynatable
var dynatableSettings = {
dataset: {
records: jsonTable
, sortTypes: {
'%': 'numberSort'
, 'Total': 'numberSort'
}
}
, features: {
@iampeterbanjo
iampeterbanjo / html-browser-classes.html
Created June 1, 2015 15:28
HTML browser classes for IE7+ including no-js
<!--[if lt IE 7 ]> <html lang="en" class="no-js lt-ie10 lt-ie9 lt-ie8 lt-ie7"> <![endif]-->
<!--[if IE 7 ]> <html lang="en" class="no-js lt-ie10 lt-ie9 lt-ie8"> <![endif]-->
<!--[if IE 8 ]> <html lang="en" class="no-js lt-ie10 lt-ie9"> <![endif]-->
<!--[if IE 9 ]> <html lang="en" class="no-js lt-ie10"> <![endif]-->
<!--[if (gt IE 9)|!(IE)]><!--> <html lang="en" class="no-js"> <!--<![endif]-->
@iampeterbanjo
iampeterbanjo / atom_packages
Created July 20, 2015 08:56
Favourite: ~/.atom/packages
atom-beautify
atom-erb
atomatigit
autocomplete-paths
color-picker
emmet
minimap
pathfinder
recent-files
seti-syntax
@iampeterbanjo
iampeterbanjo / brackets_extensions
Created July 30, 2015 16:22
Installed extensions for Brackets.io
adobe.brackets.extract
bigeyex.brackets-wordhint
bracket-match-highlighter
brackets-beautify
brackets-code-folding
brackets-css-color-preview
brackets-eco
brackets-emmet
brackets-html5codehints
brackets-indent-guides
@iampeterbanjo
iampeterbanjo / .gitconfig
Last active September 8, 2015 12:23 — forked from shawndumas/.gitconfig
Using WinMerge as the git Diff/Merge Tool on Windows 64bit
[mergetool]
prompt = false
keepBackup = false
keepTemporaries = false
[merge]
tool = winmerge
[mergetool "winmerge"]
name = WinMerge
git config --global merge.tool p4merge
git config --global mergetool.p4merge.path 'C:\Program Files\Perforce\p4merge.exe'
@iampeterbanjo
iampeterbanjo / bbq-sample.js
Created October 29, 2010 23:43
example of using bbq jQuery plug-in
//listen for hash tag changes so we can remove the popup
$(window).bind('hashchange',
function(event){
//did we add or substract the hash?
var currentHash = window.location.hash;
currentHash = currentHash.slice(1);
if(window.console && debug){
console.log(['listings.js: hashchange event detected. currentHash is ', currentHash ].join(''));
}