etnbrd/flx-compiler

View on GitHub

Showing 623 of 1,229 total issues

Function d3_geo_clipPolygon has 57 lines of code (exceeds 25 allowed). Consider refactoring.
Open

  function d3_geo_clipPolygon(segments, compare, clipStartInside, interpolate, listener) {
    var subject = [], clip = [];
    segments.forEach(function(segment) {
      if ((n = segment.length - 1) <= 0) return;
      var n, p0 = segment[0], p1 = segment[n];
Severity: Major
Found in lib/graph-printer/old/bower_components/d3/d3.js - About 2 hrs to fix

    Function render has 57 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        render: function(gl, program, data, params) {
          var buffer;
    
          // Define attributes:
          var positionLocation =

      Function initProgram has 57 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          initProgram: function(gl) {
            var vertexShader,
                fragmentShader,
                program;
      
      

        Function MRModel has a Cognitive Complexity of 17 (exceeds 5 allowed). Consider refactoring.
        Open

        module.exports = function MRModel(name, schema, opts) {
            opts = opts || {};
        
            /**
             * is overriden for liveQueries
        Severity: Minor
        Found in test-set/Moonridge-master/mr-server-model.js - About 2 hrs to fix

        Cognitive Complexity

        Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

        A method's cognitive complexity is based on a few simple rules:

        • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
        • Code is considered more complex for each "break in the linear flow of the code"
        • Code is considered more complex when "flow breaking structures are nested"

        Further reading

        Function hierarchy has 56 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

          d3.layout.hierarchy = function() {
            var sort = d3_layout_hierarchySort, children = d3_layout_hierarchyChildren, value = d3_layout_hierarchyValue;
            function hierarchy(root) {
              var stack = [ root ], nodes = [], node;
              root.depth = 0;
        Severity: Major
        Found in lib/graph-printer/old/bower_components/d3/d3.js - About 2 hrs to fix

          Function linRepulsion_antiCollision has 55 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

                linRepulsion_antiCollision: function(c) {
                  this.coefficient = c;
                  this.apply_nn = function(n1, n2) {
                    var factor;
          
          

            Function stack has 54 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

              d3.layout.stack = function() {
                var values = d3_identity, order = d3_layout_stackOrderDefault, offset = d3_layout_stackOffsetZero, out = d3_layout_stackOut, x = d3_layout_stackX, y = d3_layout_stackY;
                function stack(data, index) {
                  var series = data.map(function(d, i) {
                    return values.call(stack, d, i);
            Severity: Major
            Found in lib/graph-printer/old/bower_components/d3/d3.js - About 2 hrs to fix

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

              exports = module.exports = function(options) {
                var config = Hash({
                  rules: {},
                  stylesheets: ['/endpoint/css/reset.css',
                                  '/endpoint/css/style.css'],
              Severity: Major
              Found in test-set/express-endpoint-master/lib/middleware/errorHandler.js - About 2 hrs to fix

                Function _getKeySizeAndType has 54 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                        Overview.prototype._getKeySizeAndType = function (keys, last) {
                          var _collection, _commands, _i, _key, _len;
                          if (last) {
                            if (this._totalKeyAmount <= this._timesRequested * this.options.multiLength) {
                              this.lastKeySizeAndTypeRequest = false;
                Severity: Major
                Found in test-set/redis_key_overview-master/index-flx.js - About 2 hrs to fix

                  Function extractDown has 53 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                  function extractDown(tree, id) {
                  
                    var _n = {};
                    var __n = {};
                    var _d = {};
                  Severity: Major
                  Found in prototypes/blender.old/lib/extraction.js - About 2 hrs to fix

                    Function processCSI has a Cognitive Complexity of 16 (exceeds 5 allowed). Consider refactoring.
                    Open

                    timbits.processCSI = function(index, element) {
                      var include = jQuery(element);
                      var src = include.attr('data-csi');
                      var process_this = true;
                    
                    
                    Severity: Minor
                    Found in test-set/timbits-master/resources/javascript/timbits.csi.js - About 2 hrs to fix

                    Cognitive Complexity

                    Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                    A method's cognitive complexity is based on a few simple rules:

                    • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                    • Code is considered more complex for each "break in the linear flow of the code"
                    • Code is considered more complex when "flow breaking structures are nested"

                    Further reading

                    Function graph has a Cognitive Complexity of 16 (exceeds 5 allowed). Consider refactoring.
                    Open

                    function graph(type, options) {
                      this._options = options;
                      this._output_pre = _bgraph + "\\begin{" + type + "}";
                      this._output_post = "\\end{" + type + "}\n"+ _egraph;
                      this._plots = [];
                    Severity: Minor
                    Found in prototypes/fluxions/bench/distribution/pgfplots.js - About 2 hrs to fix

                    Cognitive Complexity

                    Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

                    A method's cognitive complexity is based on a few simple rules:

                    • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
                    • Code is considered more complex for each "break in the linear flow of the code"
                    • Code is considered more complex when "flow breaking structures are nested"

                    Further reading

                    Function d3_geom_voronoiAddBeach has 52 lines of code (exceeds 25 allowed). Consider refactoring.
                    Open

                      function d3_geom_voronoiAddBeach(site) {
                        var x = site.x, directrix = site.y, lArc, rArc, dxl, dxr, node = d3_geom_voronoiBeaches._;
                        while (node) {
                          dxl = d3_geom_voronoiLeftBreakPoint(node, directrix) - x;
                          if (dxl > ε) node = node.L; else {
                    Severity: Major
                    Found in lib/graph-printer/old/bower_components/d3/d3.js - About 2 hrs to fix

                      Function event has 52 lines of code (exceeds 25 allowed). Consider refactoring.
                      Open

                          brush.event = function(g) {
                            g.each(function() {
                              var event_ = event.of(this, arguments), extent1 = {
                                x: xExtent,
                                y: yExtent,
                      Severity: Major
                      Found in lib/graph-printer/old/bower_components/d3/d3.js - About 2 hrs to fix

                        Function d3_geom_clipLine has 52 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                          function d3_geom_clipLine(x0, y0, x1, y1) {
                            return function(line) {
                              var a = line.a, b = line.b, ax = a.x, ay = a.y, bx = b.x, by = b.y, t0 = 0, t1 = 1, dx = bx - ax, dy = by - ay, r;
                              r = x0 - ax;
                              if (!dx && r > 0) return;
                        Severity: Major
                        Found in lib/graph-printer/old/bower_components/d3/d3.js - About 2 hrs to fix

                          Function animate has 52 lines of code (exceeds 25 allowed). Consider refactoring.
                          Open

                            sigma.plugins.animate = function(s, animate, options) {
                              var o = options || {},
                                  id = ++_id,
                                  duration = o.duration || s.settings('animationsTime'),
                                  easing = typeof o.easing === 'string' ?

                            Function _reducer has 52 lines of code (exceeds 25 allowed). Consider refactoring.
                            Open

                            function _reducer() {
                            
                              function reduce(n, it) {
                            
                                function _agg(n) {
                            Severity: Major
                            Found in prototypes/shreder/lib/traverse.js - About 2 hrs to fix

                              Function initProgram has 52 lines of code (exceeds 25 allowed). Consider refactoring.
                              Open

                                  initProgram: function(gl) {
                                    var vertexShader,
                                        fragmentShader,
                                        program;
                              
                              

                                Function bind has 51 lines of code (exceeds 25 allowed). Consider refactoring.
                                Open

                                    function bind(group, groupData) {
                                      var i, n = group.length, m = groupData.length, n0 = Math.min(n, m), updateNodes = new Array(m), enterNodes = new Array(m), exitNodes = new Array(n), node, nodeData;
                                      if (key) {
                                        var nodeByKeyValue = new d3_Map(), dataByKeyValue = new d3_Map(), keyValues = [], keyValue;
                                        for (i = -1; ++i < n; ) {
                                Severity: Major
                                Found in lib/graph-printer/old/bower_components/d3/d3.js - About 2 hrs to fix

                                  Function ajaxConvert has 51 lines of code (exceeds 25 allowed). Consider refactoring.
                                  Open

                                  function ajaxConvert( s, response ) {
                                      var conv2, current, conv, tmp,
                                          converters = {},
                                          i = 0,
                                          // Work with a copy of dataTypes in case we need to modify it for conversion
                                  Severity: Major
                                  Found in test-set/gifsockets-server-master/public/js/jquery.js - About 2 hrs to fix
                                    Severity
                                    Category
                                    Status
                                    Source
                                    Language