This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script type="text/javascript"> | |
//Javascript trim() example | |
String.prototype.trim = function() { return this.replace(/^\s+|\s+$/g, ""); }; | |
//Usage: | |
var str = " foo bar "; | |
alert("Original string: '" + str + "'"); | |
str = str.trim(); | |
alert("Trimmed string: '" + str + "'"); | |
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
nmap <F2> a<C-R>=strftime("%c")<CR><Esc> | |
"http://stackoverflow.com/questions/69998/tabs-and-spaces-in-vim | |
set tabstop=4 | |
set shiftwidth=4 | |
set expandtab | |
call pathogen#infect() | |
syntax on | |
filetype plugin indent on |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var timer; | |
var originalValue = lib.getScrollTop(); | |
var alteration = lib.getPos(dom).y; | |
var currentTime = 0; | |
var duration = 50; | |
var interval = 25; | |
function action(){ | |
window.scrollTo( 0, tween.quad.easeInOut(originalValue,alteration,currentTime,duration); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let g:neocomplcache_enable_cursor_hold_i=1 | |
let g:neocomplcache_cursor_hold_i_time=300 | |
autocmd InsertEnter * call s:on_insert_enter() | |
function! s:on_insert_enter() | |
if &updatetime > g:neocomplcache_cursor_hold_i_time | |
let s:update_time_save = &updatetime | |
let &updatetime = g:neocomplcache_cursor_hold_i_time | |
endif | |
endfunction |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module.exports = function(grunt){ | |
grunt.init({ | |
//task options go here | |
}); | |
//load grunt tasks | |
grunt.loadNpmTasks('task goes here'); /* example grunt.loadNpmTasks('compass'); */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "my-app", | |
"version": "0.0.0", | |
"dependencies": { | |
"browserify": "~2.36.1", | |
"less": "~1.5.1" | |
}, | |
"devDependencies": { | |
"watchify": "~0.4.1", | |
"catw": "~0.2.0" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
node_modules/ | |
.idea/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"directory": "components" | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
this.collection.comparator = 'id'; | |
this.collection.sort(); | |
this.collection.trigger('reset'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# 0 is too far from ` ;) | |
set -g base-index 1 | |
# Automatically set window title | |
set-window-option -g automatic-rename on | |
set-option -g set-titles on | |
#set -g default-terminal screen-256color | |
set -g status-keys vi | |
set -g history-limit 10000 |
OlderNewer