Skip to content

Instantly share code, notes, and snippets.

View LeonFedotov's full-sized avatar
🐧

Leon Fedotov LeonFedotov

🐧
View GitHub Profile
@LeonFedotov
LeonFedotov / gist:4690111
Created February 1, 2013 08:33
A small script for hackathon.io - http://www.hackathon.io/events that makes tiles look better.
(function() {
var all = $('.block-grid.five-up > li').toArray();
all.slice(5).forEach(function(current, index) {
index += 5;
var el = $(current),
offset = el.offset(),
above = $(all[index-5]);
el.css({
position: 'relative',
@LeonFedotov
LeonFedotov / gist:4565843
Last active December 11, 2015 07:19
jasmine "it" function fix for async, adding another parameter to support promises and augment waitFor.
(function(){
//jasmine "it" function fix for async, adding another parameter to support promises and augment waitsFor.
var generate_promise = function() {
var promise = {
check_for: false,
waits: function() {
waitsFor(function() {
return promise.check_for;
});
},
@LeonFedotov
LeonFedotov / coffe-maps.rb
Created November 15, 2012 14:35
coffee-script with sourcemaps
COFFEE_EXEC = '/Users/leon/code/resources/CoffeeScriptRedux/bin/coffee' #https://github.com/michaelficarra/CoffeeScriptRedux/
def create_js(source)
target = "#{File.dirname(source)}/js/#{File.basename(source, '.coffee')}.js"
puts "#{COFFEE_EXEC} --js -i #{source} > #{target}"
%x{#{COFFEE_EXEC} --js -i #{source} > #{target}}
puts "#{COFFEE_EXEC} --source-map -i #{source} > #{target}.map"
%x{#{COFFEE_EXEC} --source-map -i #{source} > #{target}.map}
@LeonFedotov
LeonFedotov / gist:1918181
Created February 26, 2012 18:31
My thing for tlvjs, for lulz use only.
/**
This is the code from a presentation given in the II JS meetup TLV,
for lulz use only. - http://www.meetup.com/telavivjs/events/50068512/
comments: twitter.com/leonFedotov
________
< o HAI! >
--------
\ ^__^
\ (oo)\_______