erikroyall/hilo

View on GitHub

Showing 292 of 292 total issues

Function class has 105 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    "class": feature.classList === true ? function (action, className) {
      return this.each(function (el) {
        var _i, parts, contains, res = [];

        if (typeof className === "string") { // A String
Severity: Major
Found in src/dom.js - About 4 hrs to fix

    Identical blocks of code found in 2 locations. Consider refactoring.
    Open

    (function (A, M, D) {
    
      /* Register Hilo as an AMD module */
    
      /*globals YUI: false, module: false, define: false*/
    Severity: Major
    Found in build/hilo-legacy.js and 1 other location - About 4 hrs to fix
    build/hilo.js on lines 11..3733

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 118.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Identical blocks of code found in 2 locations. Consider refactoring.
    Open

    (function (A, M, D) {
    
      /* Register Hilo as an AMD module */
    
      /*globals YUI: false, module: false, define: false*/
    Severity: Major
    Found in build/hilo.js and 1 other location - About 4 hrs to fix
    build/hilo-legacy.js on lines 11..5763

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 118.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 3 locations. Consider refactoring.
    Open

      var forIn = function forIn (obj, fn, thisRef) {
        var _i;
    
        // Throw an error if object and function are not provided
        if (!(obj && fn)) {
    Severity: Major
    Found in src/util.js and 2 other locations - About 3 hrs to fix
    build/hilo-legacy.js on lines 3210..3228
    build/hilo.js on lines 1189..1207

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 99.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 3 locations. Consider refactoring.
    Open

      var forIn = function forIn (obj, fn, thisRef) {
        var _i;
    
        // Throw an error if object and function are not provided
        if (!(obj && fn)) {
    Severity: Major
    Found in build/hilo-legacy.js and 2 other locations - About 3 hrs to fix
    build/hilo.js on lines 1189..1207
    src/util.js on lines 117..135

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 99.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 3 locations. Consider refactoring.
    Open

      var forIn = function forIn (obj, fn, thisRef) {
        var _i;
    
        // Throw an error if object and function are not provided
        if (!(obj && fn)) {
    Severity: Major
    Found in build/hilo.js and 2 other locations - About 3 hrs to fix
    build/hilo-legacy.js on lines 3210..3228
    src/util.js on lines 117..135

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 99.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Function Sizzle has 76 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        function Sizzle(selector, context, results, seed) {
          var match, elem, m, nodeType,
            // QSA vars
            i, groups, old, nid, newContext, newSelector;
    
    
    Severity: Major
    Found in src/sizzle.js - About 3 hrs to fix

      Function Sizzle has 76 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          function Sizzle(selector, context, results, seed) {
            var match, elem, m, nodeType,
              // QSA vars
              i, groups, old, nid, newContext, newSelector;
      
      
      Severity: Major
      Found in build/hilo-legacy.js - About 3 hrs to fix

        Identical blocks of code found in 3 locations. Consider refactoring.
        Open

          var toInteger = function toInteger (value) {
            var number = +value;
        
            if (Number.isNaN(number)) {
              return 0;
        Severity: Major
        Found in src/util.js and 2 other locations - About 2 hrs to fix
        build/hilo-legacy.js on lines 3110..3122
        build/hilo.js on lines 1089..1101

        Duplicated Code

        Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

        Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

        When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

        Tuning

        This issue has a mass of 93.

        We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

        The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

        If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

        See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

        Refactorings

        Further Reading

        Identical blocks of code found in 3 locations. Consider refactoring.
        Open

          var toInteger = function toInteger (value) {
            var number = +value;
        
            if (Number.isNaN(number)) {
              return 0;
        Severity: Major
        Found in build/hilo-legacy.js and 2 other locations - About 2 hrs to fix
        build/hilo.js on lines 1089..1101
        src/util.js on lines 17..29

        Duplicated Code

        Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

        Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

        When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

        Tuning

        This issue has a mass of 93.

        We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

        The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

        If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

        See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

        Refactorings

        Further Reading

        Identical blocks of code found in 3 locations. Consider refactoring.
        Open

          var toInteger = function toInteger (value) {
            var number = +value;
        
            if (Number.isNaN(number)) {
              return 0;
        Severity: Major
        Found in build/hilo.js and 2 other locations - About 2 hrs to fix
        build/hilo-legacy.js on lines 3110..3122
        src/util.js on lines 17..29

        Duplicated Code

        Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

        Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

        When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

        Tuning

        This issue has a mass of 93.

        We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

        The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

        If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

        See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

        Refactorings

        Further Reading

        Function matcherFromGroupMatchers has 72 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

            function matcherFromGroupMatchers(elementMatchers, setMatchers) {
              // A counter to specify which element is currently being matched
              var matcherCachedRuns = 0,
                bySet = setMatchers.length > 0,
                byElement = elementMatchers.length > 0,
        Severity: Major
        Found in src/sizzle.js - About 2 hrs to fix

          Function matcherFromGroupMatchers has 72 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

              function matcherFromGroupMatchers(elementMatchers, setMatchers) {
                // A counter to specify which element is currently being matched
                var matcherCachedRuns = 0,
                  bySet = setMatchers.length > 0,
                  byElement = elementMatchers.length > 0,
          Severity: Major
          Found in build/hilo-legacy.js - About 2 hrs to fix

            Function classify has 71 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

            hilo.classify = function () {
                var body = win.Hilo("body")
                  , classes = ["js"]
                  , _i;
                // Remove the default no-js class
            Severity: Major
            Found in build/hilo-legacy.js - About 2 hrs to fix

              Function classify has 71 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

              hilo.classify = function () {
                  var body = win.Hilo("body")
                    , classes = ["js"]
                    , _i;
                  // Remove the default no-js class
              Severity: Major
              Found in build/hilo.js - About 2 hrs to fix

                Function classify has 71 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                  hilo.classify = function () {
                    var body = win.Hilo("body")
                      , classes = ["js"]
                      , _i;
                    // Remove the default no-js class
                Severity: Major
                Found in src/misc.js - About 2 hrs to fix

                  Similar blocks of code found in 3 locations. Consider refactoring.
                  Open

                    var extend = function extend (obj, ext) {
                      var _i;
                  
                      // Throw an error if object and extension are not provided
                      if (!(obj && ext)) {
                  Severity: Major
                  Found in build/hilo-legacy.js and 2 other locations - About 2 hrs to fix
                  build/hilo.js on lines 1210..1227
                  src/util.js on lines 138..155

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 88.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 3 locations. Consider refactoring.
                  Open

                    var extend = function extend (obj, ext) {
                      var _i;
                  
                      // Throw an error if object and extension are not provided
                      if (!(obj && ext)) {
                  Severity: Major
                  Found in build/hilo.js and 2 other locations - About 2 hrs to fix
                  build/hilo-legacy.js on lines 3231..3248
                  src/util.js on lines 138..155

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 88.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Similar blocks of code found in 3 locations. Consider refactoring.
                  Open

                    var extend = function extend (obj, ext) {
                      var _i;
                  
                      // Throw an error if object and extension are not provided
                      if (!(obj && ext)) {
                  Severity: Major
                  Found in src/util.js and 2 other locations - About 2 hrs to fix
                  build/hilo-legacy.js on lines 3231..3248
                  build/hilo.js on lines 1210..1227

                  Duplicated Code

                  Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

                  Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

                  When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

                  Tuning

                  This issue has a mass of 88.

                  We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

                  The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

                  If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

                  See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

                  Refactorings

                  Further Reading

                  Function setMatcher has 66 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                      function setMatcher(preFilter, selector, matcher, postFilter, postFinder, postSelector) {
                        if (postFilter && !postFilter[expando]) {
                          postFilter = setMatcher(postFilter);
                        }
                        if (postFinder && !postFinder[expando]) {
                  Severity: Major
                  Found in build/hilo-legacy.js - About 2 hrs to fix
                    Severity
                    Category
                    Status
                    Source
                    Language