app/assets/javascripts/lib/odometer.js
File odometer.js
has 575 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
(function() {
var COUNT_FRAMERATE, COUNT_MS_PER_FRAME, DIGIT_FORMAT, DIGIT_HTML, DIGIT_SPEEDBOOST, DURATION, FORMAT_MARK_HTML, FORMAT_PARSER, FRAMERATE, FRAMES_PER_VALUE, MS_PER_FRAME, MutationObserver, Odometer, RIBBON_HTML, TRANSITION_END_EVENTS, TRANSITION_SUPPORT, VALUE_HTML, addClass, createFromHTML, fractionalPart, now, removeClass, requestAnimationFrame, round, transitionCheckStyles, trigger, truncate, wrapJQuery, _jQueryWrapped, _old, _ref, _ref1,
__slice = [].slice;
VALUE_HTML = '<span class="odometer-value"></span>';
Function animateSlide
has 81 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
Odometer.prototype.animateSlide = function(newValue) {
var boosted, cur, diff, digitCount, digits, dist, end, fractionalCount, frame, frames, i, incr, j, mark, numEl, oldValue, start, _base, _i, _j, _k, _l, _len, _len1, _len2, _m, _ref, _results;
oldValue = this.value;
fractionalCount = this.getFractionalDigitCount(oldValue, newValue);
if (fractionalCount) {
Function Odometer
has 50 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function Odometer(options) {
var e, k, property, v, _base, _i, _len, _ref, _ref1, _ref2,
_this = this;
this.options = options;
this.el = this.options.el;
Function render
has 46 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
Odometer.prototype.render = function(value) {
var classes, cls, digit, match, newClasses, theme, wholePart, _i, _j, _len, _len1, _ref;
if (value == null) {
value = this.value;
}
Function addDigit
has 32 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
Odometer.prototype.addDigit = function(value, repeating) {
var chr, digit, resetted, _ref;
if (repeating == null) {
repeating = true;
}
Function animateCount
has 29 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
Odometer.prototype.animateCount = function(newValue) {
var cur, diff, last, start, tick,
_this = this;
if (!(diff = +newValue - this.value)) {
return;