Skip to content

Instantly share code, notes, and snippets.

Avatar

Jamis Charles jamischarles

View GitHub Profile
View vim-on-heroku.sh
#!/usr/bin/env bash
mkdir vim
curl https://s3.amazonaws.com/heroku-vim/vim-7.3.tar.gz --location --silent | tar xz -C vim
export PATH=$PATH:/app/vim/bin
@leommoore
leommoore / javascript_ANSI_escape_codes.md
Last active Jan 18, 2021
JavaScript - ANSI Escape Codes
View javascript_ANSI_escape_codes.md

JavaScript - ANSI Escape Codes

ANSI Escape Codes are special characters which can be used to control formatting, colors or other output preferences in a text terminal. Escape Codes are non-printing code and will not appear in the output directly.

  • \033 begins the escape sequence
  • [ indicates the color
  • 33 is the foreground color for yellow
  • m indicates the end of the setting

Note: \033[39m is used set the color back to the terminal defult

View nodejs_express_file-structure.markdown

consider making a node-guides site like rails guides?

Approach 1:

TJ HollowayChuck (creator of Express)

"personally I find large rails-style structure difficult to work with for large applications (great for small ones however). A more modular approach like Drupal is a big win as far as management goes but it can complicate some things (layout templates) so you kind of need

@tmahesh
tmahesh / measurePageloadTimes.js
Created Feb 18, 2011
How fast is my site? integrate boomerang and google analytics
View measurePageloadTimes.js
<script type="text/javascript">
BOOMR.init({
beacon_url: "/boomerang.gif",
BW: {
enabled: false
}
});
BOOMR.subscribe('before_beacon', trackInAnalytics);
var pageType = "homepage"; // customize this