Skip to content

Instantly share code, notes, and snippets.

/*
The view.$el property is equivalent to $(view.el) and view.$(selector) is equivalent to $(view.el).find(selector)
*/
view.$(selector)
@davidsp
davidsp / commands
Last active August 29, 2015 13:57
useful git commands
git add -u
git add --all
cat .gitignore
git add --force
--update from origin
git pull origin
@davidsp
davidsp / dev-mixins.less
Created March 10, 2014 17:02
A collection of less mixins
.text-replace() {
text-indent: 100%;
white-space: nowrap;
overflow: hidden;
}
#grid-w {
font-size: 0;
.col-w(@xPerc){
font-size: @baseFontSize;
@davidsp
davidsp / Object patterns
Last active August 29, 2015 13:57
List of Object patterns for js (extracted from The Principles of Object-Oriented JavaScript, by Nicholas C.Zakas)
//Object patterns extracted from the 6th chapter of The Principles of Object-Oriented JavaScript, by Nicholas C.Zakas.
//http://shop.oreilly.com/product/9781593275402.do