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
FAILED | |
http://butunclebob.com/ArticleS.UncleBob.ThePrimeFactorsKata | |
Notes (cos I had to look up what Prime Factors were): | |
===================================================== | |
http://en.wikipedia.org/wiki/Prime_factor | |
Prime factors of a number are the prime numbers you would multiply together to get that original number as a result, e.g: |
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
# Installs migrations from unmountable engines | |
bundle exec rake railties:install:migrations FROM=<ENGINE-NAME>_engine |
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
$(window).bind('orientationchange', function(){ | |
// do whatever | |
}); | |
// The below will give you the current orientation for iOS devices, possible values being 0, 90, -90 or 180 (180 on iPad only) | |
if (navigator.userAgent.match(/(iPod|iPhone|iPad)/)) { | |
alert(window.orientation); | |
} |
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
jQuery.fn.fitToParent = function() | |
{ | |
this.each(function() | |
{ | |
var width = $(this).width(); | |
var height = $(this).height(); | |
var parentWidth = $(this).parent().width(); | |
var parentHeight = $(this).parent().height(); | |
if(width/parentWidth < height/parentHeight) |
NewerOlder