Skip to content

Instantly share code, notes, and snippets.

View jofi's full-sized avatar

Jozef Fulop jofi

View GitHub Profile
@jofi
jofi / Jaascript Classes
Created May 2, 2014 06:54
JavaScript classes
function Something(attr) {
this.attr = attr;
this.doSomething();
this.initSomething();
$(this.activator).bind('click', {editor: this}, this.clickHandler);
};
Something.prototype = {
doSomething: function() {
// blabla bla
:w !sudo tee %
ruby -e 'puts `echo $PATH`.split ":"'
#!/usr/bin/env ruby
if __FILE__ == $PROGRAM_NAME
$:.unshift(File.expand_path('../lib', __FILE__))
#require 'something'
#some code...
#require 'pry'
#Pry.start