jquery/jquery

View on GitHub

Showing 228 of 250 total issues

Function select has 50 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function select( selector, context, results, seed ) {
    var i, tokens, token, type, find,
        compiled = typeof selector === "function" && selector,
        match = !seed && tokenize( ( selector = compiled.selector || selector ) );

Severity: Minor
Found in src/selector.js - About 2 hrs to fix

    Consider simplifying this complex logical expression.
    Open

                    if ( ( mappedTypes || origType === handleObj.origType ) &&
                        ( !handler || handler.guid === handleObj.guid ) &&
                        ( !tmp || tmp.test( handleObj.namespace ) ) &&
                        ( !selector || selector === handleObj.selector ||
                            selector === "**" && handleObj.selector ) ) {
    Severity: Critical
    Found in src/event.js - About 2 hrs to fix

      Function diffCleanupEfficiency has 49 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

            DiffMatchPatch.prototype.diffCleanupEfficiency = function (diffs) {
                var changes, equalities, equalitiesLength, lastequality, pointer, preIns, preDel, postIns, postDel;
                changes = false;
                equalities = []; // Stack of indices where equalities are found.
                equalitiesLength = 0; // Keeping our own length var is faster in JS.
      Severity: Minor
      Found in external/qunit/qunit.js - About 1 hr to fix

        Function matcherFromTokens has 47 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

        function matcherFromTokens( tokens ) {
            var checkContext, matcher, j,
                len = tokens.length,
                leadingRelative = Expr.relative[ tokens[ 0 ].type ],
                implicitRelative = leadingRelative || Expr.relative[ " " ],
        Severity: Minor
        Found in src/selector.js - About 1 hr to fix

          Function tokenize has 47 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

          function tokenize( selector, parseOnly ) {
              var matched, match, tokens, type,
                  soFar, groups, preFilters,
                  cached = tokenCache[ selector + " " ];
          
          
          Severity: Minor
          Found in src/selector.js - About 1 hr to fix

            Function exports has 46 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

            module.exports = function( grunt ) {
            
                "use strict";
            
                var    fs = require( "fs" ),
            Severity: Minor
            Found in build/tasks/dist.js - About 1 hr to fix

              Function enable has 46 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                          enable: function () {
                              enabledRegistry[this.map.id] = this;
                              this.enabled = true;
              
                              //Set flag mentioning that the module is enabling,
              Severity: Minor
              Found in external/requirejs/require.js - About 1 hr to fix

                Function addCombinator has 45 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                function addCombinator( matcher, combinator, base ) {
                    var dir = combinator.dir,
                        skip = combinator.next,
                        key = skip || dir,
                        checkNonElements = base && key === "parentNode",
                Severity: Minor
                Found in src/selector.js - About 1 hr to fix

                  Function val has 45 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                      val: function( value ) {
                          var hooks, ret, valueIsFunction,
                              elem = this[ 0 ];
                  
                          if ( !arguments.length ) {
                  Severity: Minor
                  Found in src/attributes/val.js - About 1 hr to fix

                    Function leverageNative has 44 lines of code (exceeds 25 allowed). Consider refactoring.
                    Open

                    function leverageNative( el, type, expectSync ) {
                    
                        // Missing expectSync indicates a trigger call, which must force setup through jQuery.event.add
                        if ( !expectSync ) {
                            if ( dataPriv.get( el, type ) === undefined ) {
                    Severity: Minor
                    Found in src/event.js - About 1 hr to fix

                      Function data has 44 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                          data: function( key, value ) {
                              var i, name, data,
                                  elem = this[ 0 ],
                                  attrs = elem && elem.attributes;
                      
                      
                      Severity: Minor
                      Found in src/data.js - About 1 hr to fix

                        Function diffLineMode has 44 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                              DiffMatchPatch.prototype.diffLineMode = function (text1, text2, deadline) {
                                  var a, diffs, linearray, pointer, countInsert, countDelete, textInsert, textDelete, j;
                        
                                  // Scan the text on a line-by-line basis first.
                                  a = this.diffLinesToChars(text1, text2);
                        Severity: Minor
                        Found in external/qunit/qunit.js - About 1 hr to fix

                          Function extend has 43 lines of code (exceeds 25 allowed). Consider refactoring.
                          Open

                          jQuery.extend = jQuery.fn.extend = function() {
                              var options, name, src, copy, copyIsArray, clone,
                                  target = arguments[ 0 ] || {},
                                  i = 1,
                                  length = arguments.length,
                          Severity: Minor
                          Found in src/core.js - About 1 hr to fix

                            Function exports has 43 lines of code (exceeds 25 allowed). Consider refactoring.
                            Open

                            module.exports = function( Release ) {
                            
                                var
                                    files = [
                                        "dist/jquery.js",
                            Severity: Minor
                            Found in build/release.js - About 1 hr to fix

                              Function Test has 43 lines of code (exceeds 25 allowed). Consider refactoring.
                              Open

                                function Test(settings) {
                                    var i, l;
                              
                                    ++Test.count;
                              
                              
                              Severity: Minor
                              Found in external/qunit/qunit.js - About 1 hr to fix

                                Function makeArchives has 42 lines of code (exceeds 25 allowed). Consider refactoring.
                                Open

                                function makeArchives( Release, callback ) {
                                
                                    Release.chdir( Release.dir.repo );
                                
                                    function makeArchive( cdn, files, callback ) {
                                Severity: Minor
                                Found in build/release/cdn.js - About 1 hr to fix

                                  Function getUrlConfigHtml has 42 lines of code (exceeds 25 allowed). Consider refactoring.
                                  Open

                                        function getUrlConfigHtml() {
                                            var i,
                                                j,
                                                val,
                                                escaped,
                                  Severity: Minor
                                  Found in external/qunit/qunit.js - About 1 hr to fix

                                    Function stop has 41 lines of code (exceeds 25 allowed). Consider refactoring.
                                    Open

                                        stop: function( type, clearQueue, gotoEnd ) {
                                            var stopQueue = function( hooks ) {
                                                var stop = hooks.stop;
                                                delete hooks.stop;
                                                stop( gotoEnd );
                                    Severity: Minor
                                    Found in src/effects.js - About 1 hr to fix

                                      Function adjustCSS has 41 lines of code (exceeds 25 allowed). Consider refactoring.
                                      Open

                                      function adjustCSS( elem, prop, valueParts, tween ) {
                                          var adjusted, scale,
                                              maxIterations = 20,
                                              currentValue = tween ?
                                                  function() {
                                      Severity: Minor
                                      Found in src/css/adjustCSS.js - About 1 hr to fix

                                        Function access has 41 lines of code (exceeds 25 allowed). Consider refactoring.
                                        Open

                                        var access = function( elems, fn, key, value, chainable, emptyGet, raw ) {
                                            var i = 0,
                                                len = elems.length,
                                                bulk = key == null;
                                        
                                        
                                        Severity: Minor
                                        Found in src/core/access.js - About 1 hr to fix
                                          Severity
                                          Category
                                          Status
                                          Source
                                          Language