Showing 301 of 580 total issues
File fore.js
has 5496 lines of code (exceeds 250 allowed). Consider refactoring. Open
module.exports = [
"Aaron"
, "Aaron"
, "Abbey"
Function Labeler
has 300 lines of code (exceeds 25 allowed). Consider refactoring. Open
var Labeler = augment(Object, function() {
this.constructor = function(transitive) {
this.transitive = transitive;
File edge.js
has 550 lines of code (exceeds 250 allowed). Consider refactoring. Open
var each = require('each');
var PriorityQueue = require('priorityqueuejs');
var Util = require('../util');
Function MultiPoint
has a Cognitive Complexity of 54 (exceeds 5 allowed). Consider refactoring. Open
var MultiPoint = augment(Point, function(base) {
this.constructor = function(pointArray) {
base.constructor.call(this);
this.points = [];
- 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 Point
has 198 lines of code (exceeds 25 allowed). Consider refactoring. Open
var Point = augment(Object, function() {
this.constructor = function(data) {
for (var key in data) {
this[key] = data[key];
Function DefaultRenderer
has 190 lines of code (exceeds 25 allowed). Consider refactoring. Open
var DefaultRenderer = augment(Renderer, function(base) {
this.constructor = function(transitive) {
base.constructor.call(this, transitive);
};
Function Stop
has a Cognitive Complexity of 49 (exceeds 5 allowed). Consider refactoring. Open
var Stop = augment(Point, function(base) {
this.constructor = function(data) {
base.constructor.call(this, data);
- 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
File index.js
has 480 lines of code (exceeds 250 allowed). Consider refactoring. Open
var d3 = require('d3');
var debug = require('debug')('transitive:graph');
var each = require('each');
var clone = require('clone');
var PriorityQueue = require('priorityqueuejs');
Function convertOtpData
has 180 lines of code (exceeds 25 allowed). Consider refactoring. Open
Profiler.prototype.convertOtpData = function(opts) {
var self = this;
self.data = {
journeys: [],
patterns: [],
Function PointLabel
has 176 lines of code (exceeds 25 allowed). Consider refactoring. Open
var PointLabel = augment(Label, function(base) {
this.constructor = function(parent) {
base.constructor.call(this, parent);
Function getRenderCoords
has a Cognitive Complexity of 45 (exceeds 5 allowed). Consider refactoring. Open
Edge.prototype.getRenderCoords = function(fromOffsetPx, toOffsetPx, display, forward) {
var fromOffsetX, fromOffsetY;
var isBase = (fromOffsetPx === 0 && toOffsetPx === 0);
if (!this.baseRenderCoords && !isBase) {
- 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 PointLabel
has a Cognitive Complexity of 45 (exceeds 5 allowed). Consider refactoring. Open
var PointLabel = augment(Label, function(base) {
this.constructor = function(parent) {
base.constructor.call(this, parent);
- 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
File index.js
has 453 lines of code (exceeds 250 allowed). Consider refactoring. Open
var Batch = require('batch');
var clone, each;
var superagent = require('superagent');
try {
Function MultiPoint
has 160 lines of code (exceeds 25 allowed). Consider refactoring. Open
var MultiPoint = augment(Point, function(base) {
this.constructor = function(pointArray) {
base.constructor.call(this);
this.points = [];
Function Stop
has 159 lines of code (exceeds 25 allowed). Consider refactoring. Open
var Stop = augment(Point, function(base) {
this.constructor = function(data) {
base.constructor.call(this, data);
File index.js
has 415 lines of code (exceeds 250 allowed). Consider refactoring. Open
var Batch = require('batch')
var model = require('component-model')
var qs = require('component-querystring')
const typ = require('component-type')
const ll = require('@conveyal/lonlat')
File client.js
has 414 lines of code (exceeds 250 allowed). Consider refactoring. Open
/**
* Module dependencies.
*/
var Emitter = require('emitter');
File network.js
has 389 lines of code (exceeds 250 allowed). Consider refactoring. Open
var each = require('each');
var debug = require('debug')('transitive:network');
var Emitter = require('emitter');
var NetworkPath = require('./path');
Function SphericalMercator
has a Cognitive Complexity of 31 (exceeds 5 allowed). Consider refactoring. Open
var SphericalMercator = (function() {
// Closures including constants and other precalculated values.
var cache = {},
EPSLN = 1.0e-10,
- 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 SphericalMercator
has 112 lines of code (exceeds 25 allowed). Consider refactoring. Open
var SphericalMercator = (function() {
// Closures including constants and other precalculated values.
var cache = {},
EPSLN = 1.0e-10,