Skip to content

Instantly share code, notes, and snippets.

@oraricha
oraricha / Theme editor.md
Last active December 18, 2015 08:59
List of my sublime text 2 installed packages
var loggedInDeferred = $.Deferred();
//Data().method("isLoggedin")
loggedInDeferred = Account("isLoggedin");
loggedInDeferred = isLoggedin();
@oraricha
oraricha / code
Created August 29, 2013 16:24
Invalidate session on tab or window close (not tested!!)
/*JS code begins here*/
/*Global js variable to decide whether to call session invalidate function*/
var validNavigation = false;
//Called when page loads initially
jQuery(document).ready(function() {
//Call to wireupEvents
wireUpEvents();
@oraricha
oraricha / javascript-books.md
Created October 28, 2013 17:08 — forked from jookyboi/javascript_resources.md
Here are a set of libraries, plugins and guides which may be useful to your Javascript coding.
@oraricha
oraricha / css_resources.md
Created October 28, 2013 17:08 — forked from jookyboi/css_resources.md
CSS libraries and guides to bring some order to the chaos.

Libraries

  • 960 Grid System - An effort to streamline web development workflow by providing commonly used dimensions, based on a width of 960 pixels. There are two variants: 12 and 16 columns, which can be used separately or in tandem.
  • Compass - Open source CSS Authoring Framework.
  • Bootstrap - Sleek, intuitive, and powerful mobile first front-end framework for faster and easier web development.
  • Font Awesome - The iconic font designed for Bootstrap.
  • Zurb Foundation - Framework for writing responsive web sites.
  • SASS - CSS extension language which allows variables, mixins and rules nesting.
  • Skeleton - Boilerplate for responsive, mobile-friendly development.

Guides

@oraricha
oraricha / rails_resources.md
Created October 28, 2013 17:08 — forked from jookyboi/rails_resources.md
Rails-related Gems and guides to accelerate your web project.

Gems

  • Bundler - Bundler maintains a consistent environment for ruby applications. It tracks an application's code and the rubygems it needs to run, so that an application will always have the exact gems (and versions) that it needs to run.
  • rabl - General ruby templating with json, bson, xml, plist and msgpack support
  • Thin - Very fast and lightweight Ruby web server
  • Unicorn - Unicorn is an HTTP server for Rack applications designed to only serve fast clients on low-latency, high-bandwidth connections and take advantage of features in Unix/Unix-like kernels.
  • SimpleCov - SimpleCov is a code coverage analysis tool for Ruby 1.9.
  • Zeus - Zeus preloads your Rails app so that your normal development tasks such as console, server, generate, and specs/tests take less than one second.
  • [factory_girl](h
@oraricha
oraricha / stickyHeader.js
Created October 28, 2013 17:12
Sticky thead for table Headers - a jquery plugin
/*
Massively Improved, Fixed & Documented by @OrAricha
Based on http://web-gladiator.com/stickythead/Index.html
@author: Konstantin Meiklyar - 2013
http://web-gladiator.com/stickythead/Index.html
dependancies: jquery
@oraricha
oraricha / printable-image-replacement-mixin
Created December 9, 2013 16:28
*printable* image replacement Sass mixin
// *printable* image replacement
@mixin printable-image-replacement($imageUrl) {
display: list-item;
list-style-image: url($imageUrl);
list-style-position: inside;
letter-spacing: -1000em;
font-size: 1pt;
color: #fff;
height: image-height($imageUrl);
width: image-width($imageUrl);
@oraricha
oraricha / holidays.js
Created December 22, 2013 13:10
Snowflakes canvas generator
// as seen at http://gtaforums.com/
$j(document).ready(function() {
window.disableSnow = false;
//canvas init
var canvas = document.getElementById("canvas");
var ctx = canvas.getContext("2d");
//canvas dimensions