angular/angular-hint

View on GitHub

Showing 82 of 90 total issues

Function compile has 26 lines of code (exceeds 25 allowed). Consider refactoring.
Open

$delegate[0].compile = function(element, attrs, transclude) {
var linkFn = originalCompileFn.apply(this, arguments);
 
return function ngEventHandler(scope, element, attrs) {
var boundFuncs = getFunctionNames(attrs[ngEventAttrName]);
Severity: Minor
Found in src/modules/events.js - About 1 hr to fix

    Function forEach has 26 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    function forEach(obj, iterator, context) {
    var key, length;
    if (obj) {
    if (isFunction(obj)) {
    for (key in obj) {
    Severity: Minor
    Found in src/lib/debug-parse.js - About 1 hr to fix

      Function filter has 26 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

      filter: function(inputFn) {
      var fn = this.$filter(this.consume().text);
      var argsFn;
      var args;
       
       
      Severity: Minor
      Found in src/lib/debug-parse.js - About 1 hr to fix

        Function ensureSafeObject has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
        Open

        function ensureSafeObject(obj, fullExpression) {
        // nifty check if obj is Function that is fast and works across iframes and other contexts
        if (obj) {
        if (obj.constructor === obj) {
        throw $parseMinErr('isecfn',
        Severity: Minor
        Found in src/lib/debug-parse.js - About 55 mins to fix

        Function exports has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
        Open

        module.exports = function(doms) {
        var bothFound,
        ngViewFound,
        elem,
        isElemName,
        Severity: Minor
        Found in src/modules/angular-hint-modules/storeNgAppAndView.js - About 55 mins to fix

        Function cspSafeGetterFn has 7 arguments (exceeds 4 allowed). Consider refactoring.
        Open

        function cspSafeGetterFn(key0, key1, key2, key3, key4, fullExp, expensiveChecks) {
        Severity: Major
        Found in src/lib/debug-parse.js - About 50 mins to fix

          Avoid deeply nested control flow statements.
          Open

          for (key in obj) {
          if (obj.hasOwnProperty(key)) {
          iterator.call(context, obj[key], key, obj);
          }
          }
          Severity: Major
          Found in src/lib/debug-parse.js - About 45 mins to fix

            Avoid deeply nested control flow statements.
            Open

            if (isObject(source[key])) {
            stackSource.push(source[key]);
            stackDest.push(result);
            }
            Severity: Major
            Found in src/lib/debug-parse.js - About 45 mins to fix

              Avoid deeply nested control flow statements.
              Open

              if (!isDate(o2)) return false;
              Severity: Major
              Found in src/lib/debug-parse.js - About 45 mins to fix

                Avoid deeply nested control flow statements.
                Open

                for (key = 0; key < length; key++) {
                if (!equals(o1[key], o2[key])) return false;
                }
                Severity: Major
                Found in src/lib/debug-parse.js - About 45 mins to fix

                  Avoid deeply nested control flow statements.
                  Open

                  if (isPrimitive || key in obj) {
                  iterator.call(context, obj[key], key, obj);
                  }
                  Severity: Major
                  Found in src/lib/debug-parse.js - About 45 mins to fix

                    Avoid deeply nested control flow statements.
                    Open

                    } else if (isRegExp(o1) && isRegExp(o2)) {
                    return o1.toString() == o2.toString();
                    } else {
                    if (isScope(o1) || isScope(o2) || isWindow(o1) || isWindow(o2) || isArray(o2)) return false;
                    keySet = {};
                    Severity: Major
                    Found in src/lib/debug-parse.js - About 45 mins to fix

                      Function arrayDeclaration has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
                      Open

                      arrayDeclaration: function() {
                      var elementFns = [];
                      if (this.peekToken().text !== ']') {
                      do {
                      if (this.peek(']')) {
                      Severity: Minor
                      Found in src/lib/debug-parse.js - About 45 mins to fix

                      Function peekAhead has 5 arguments (exceeds 4 allowed). Consider refactoring.
                      Open

                      peekAhead: function(i, e1, e2, e3, e4) {
                      Severity: Minor
                      Found in src/lib/debug-parse.js - About 35 mins to fix

                        Function ternary has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
                        Open

                        ternary: function() {
                        var left = this.logicalOR();
                        var middle;
                        var token;
                        if ((token = this.expect('?'))) {
                        Severity: Minor
                        Found in src/lib/debug-parse.js - About 35 mins to fix

                        Function getterFn has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
                        Open

                        function getterFn(path, options, fullExp) {
                        var expensiveChecks = options.expensiveChecks;
                        var getterFnCache = (expensiveChecks ? getterFnCacheExpensive : getterFnCacheDefault);
                        var fn = getterFnCache[path];
                        if (fn) return fn;
                        Severity: Minor
                        Found in src/lib/debug-parse.js - About 35 mins to fix

                        Avoid too many return statements within this function.
                        Open

                        return true;
                        Severity: Major
                        Found in src/lib/debug-parse.js - About 30 mins to fix

                          Avoid too many return statements within this function.
                          Open

                          if (isScope(o1) || isScope(o2) || isWindow(o1) || isWindow(o2) || isArray(o2)) return false;
                          Severity: Major
                          Found in src/lib/debug-parse.js - About 30 mins to fix

                            Avoid too many return statements within this function.
                            Open

                            if (pathVal == null) { onUndefined([key0, key1, key2, key3, key4].join('.')); return };
                            Severity: Major
                            Found in src/lib/debug-parse.js - About 30 mins to fix

                              Avoid too many return statements within this function.
                              Open

                              if (pathVal == null) { onUndefined([key0, key1, key2, key3].join('.')); return };
                              Severity: Major
                              Found in src/lib/debug-parse.js - About 30 mins to fix
                                Severity
                                Category
                                Status
                                Source
                                Language