Showing 203 of 447 total issues
Function getContent
has 172 lines of code (exceeds 25 allowed). Consider refactoring. Open
function getContent(name, project) {
var i, j, w;
var content = [];
var graph = project.design.graph;
var connections = {
Function graphToCells
has 161 lines of code (exceeds 25 allowed). Consider refactoring. Open
function graphToCells(_graph, opt) {
// Options:
// - new: assign a new id to all the cells
// - reset: clear I/O blocks values
// - disabled: set disabled flag to the blocks
Function updateBox
has 141 lines of code (exceeds 25 allowed). Consider refactoring. Open
updateBox: function () {
'use strict';
var pendingTasks = [];
var i, port;
File joint.routers.js
has 400 lines of code (exceeds 250 allowed). Consider refactoring. Open
/* eslint-disable new-cap */
joint.routers.ice = (function (g, _, joint) {
'use strict';
Function iceRok
has 128 lines of code (exceeds 25 allowed). Consider refactoring. Open
let iceRok = function (port) {
this.tcps = {
port: 9999,
connected: false,
server: false,
Function _setProjectInformation
has 126 lines of code (exceeds 25 allowed). Consider refactoring. Open
function _setProjectInformation() {
var values = getProjectInformation();
var i;
var content = [];
Function iceRok
has a Cognitive Complexity of 32 (exceeds 5 allowed). Consider refactoring. Open
let iceRok = function (port) {
this.tcps = {
port: 9999,
connected: false,
server: false,
- Read upRead up
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 updateBox
has a Cognitive Complexity of 32 (exceeds 5 allowed). Consider refactoring. Open
updateBox: function () {
'use strict';
var pendingTasks = [];
var i, j, port;
- Read upRead up
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 verilogCompiler
has 113 lines of code (exceeds 25 allowed). Consider refactoring. Open
function verilogCompiler(name, project, opt) {
var i,
data,
block,
code = '';
File joint.selection.js
has 342 lines of code (exceeds 250 allowed). Consider refactoring. Open
/*
Copyright (c) 2016-2019 FPGAwars
Copyright (c) 2013 client IO
*/
Function serialManager
has 104 lines of code (exceeds 25 allowed). Consider refactoring. Open
var serialManager = function () {
this.devices = [];
this.info = {
status: false,
dev: -1,
Function editBasicOutputLabel
has 104 lines of code (exceeds 25 allowed). Consider refactoring. Open
function editBasicOutputLabel(cellView, callback) {
var graph = cellView.paper.model;
var block = cellView.model.attributes;
var formSpecs = [
{
Function editBasicInput
has 101 lines of code (exceeds 25 allowed). Consider refactoring. Open
function editBasicInput(cellView, callback) {
var graph = cellView.paper.model;
var block = cellView.model.attributes;
var formSpecs = [
{
File preferences.js
has 334 lines of code (exceeds 250 allowed). Consider refactoring. Open
// Please note that $uibModalInstance represents a modal window (instance) dependency.
// It is not the same as the $uibModal service.
/* eslint-disable camelcase */
Consider simplifying this complex logical expression. Open
if (
event.keyCode === command.key &&
event.altKey === (command.alt || false) &&
event.ctrlKey === (command.ctrl || false) &&
event.metaKey === (command.meta || false) &&
Function updateBifurcations
has 100 lines of code (exceeds 25 allowed). Consider refactoring. Open
updateBifurcations: function () {
'use strict';
if (this._V.markerBifurcations) {
var self = this;
Function findRoute
has 99 lines of code (exceeds 25 allowed). Consider refactoring. Open
function findRoute(start, end, map, opt) {
var step = opt.step;
var startPoints, endPoints;
var startCenter, endCenter;
Function addCommand
has a Cognitive Complexity of 27 (exceeds 5 allowed). Consider refactoring. Open
addCommand: function (cmdName, cell, graph, options) {
'use strict';
if (cmdName === 'change:labels' || cmdName === 'change:z') {
return;
- Read upRead up
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 initialize
has 97 lines of code (exceeds 25 allowed). Consider refactoring. Open
initialize: function () {
'use strict';
_.bindAll(this, 'updateBox');
joint.dia.ElementView.prototype.initialize.apply(this, arguments);
Function validateConnection
has 95 lines of code (exceeds 25 allowed). Consider refactoring. Open
validateConnection: function (
cellViewS,
magnetS,
cellViewT,
magnetT,