thinkingmedia/grunt-readme-plus

View on GitHub

Showing 40 of 48 total issues

Function Module has 149 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function Module(_, fs, os, LinkedList, Logger, Arrays) {

    /**
     * Defines a section in the readme file.
     *
Severity: Major
Found in src/Plus/Files/Markdown.js - About 5 hrs to fix

Function Module has a Cognitive Complexity of 27 (exceeds 5 allowed). Consider refactoring.
Open

function Module(_, fs, os, LinkedList, Logger, Arrays) {

    /**
     * Defines a section in the readme file.
     *
Severity: Minor
Found in src/Plus/Files/Markdown.js - About 3 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 Module has 94 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function Module(_, fs, Cache) {

    /**
     * @memberof Plus.Services
     * @constructor
Severity: Major
Found in src/Plus/Services/CacheFactory.js - About 3 hrs to fix

Function Module has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring.
Open

function Module(_, fs, Cache) {

    /**
     * @memberof Plus.Services
     * @constructor
Severity: Minor
Found in src/Plus/Services/CacheFactory.js - About 3 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 Module has 93 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function Module(Q, _, Logger, Filter, MultiMap, Section, Arrays) {

    /**
     * @memberof Plus.Engine
     *
Severity: Major
Found in src/Plus/Engine/Filters.js - About 3 hrs to fix

Function Module has a Cognitive Complexity of 24 (exceeds 5 allowed). Consider refactoring.
Open

function Module(Q, _, Logger, Filter, MultiMap, Section, Arrays) {

    /**
     * @memberof Plus.Engine
     *
Severity: Minor
Found in src/Plus/Engine/Filters.js - About 3 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 Module has a Cognitive Complexity of 23 (exceeds 5 allowed). Consider refactoring.
Open

function Module(Section, Logger) {

    /**
     * A collections container for instances of Plus.Engine.Section objects.
     *
Severity: Minor
Found in src/Plus/Engine/Sections.js - About 3 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 Module has a Cognitive Complexity of 20 (exceeds 5 allowed). Consider refactoring.
Open

function Module(_, shell, Logger) {

    /**
     * @todo this should be made lazy so it's run only when needed.
     * @memberof Plus.Services
Severity: Minor
Found in src/Plus/Services/Git.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 Module has 67 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function Module(Section, Logger) {

    /**
     * A collections container for instances of Plus.Engine.Section objects.
     *
Severity: Major
Found in src/Plus/Engine/Sections.js - About 2 hrs to fix

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

module.exports = function (grunt) {

    grunt.loadTasks('tasks');

    grunt.loadNpmTasks('grunt-jsdoc');
Severity: Major
Found in Gruntfile.js - About 2 hrs to fix

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

function Module(_) {

    /**
     * @memberof Plus.Services
     * @constructor
Severity: Minor
Found in src/Plus/Services/Similarity.js - About 2 hrs to fix

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

function Module(_, shell, Logger) {

    /**
     * @todo this should be made lazy so it's run only when needed.
     * @memberof Plus.Services
Severity: Minor
Found in src/Plus/Services/Git.js - About 1 hr to fix

Function Module has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring.
Open

function Module(module, path, fs) {

    /**
     * @memberof Plus.Services
     * @param {string} fileName
Severity: Minor
Found in src/Plus/Services/PackageJSON.js - About 1 hr 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 Module has 46 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function Module(module, _, fs, /** Plus.Engine */Engine, /**Plus.Files.Markdown*/Markdown, /**Plus.Collections.Arrays*/Arrays) {

    /**
     * @param {string} path
     * @returns {string[]}
Severity: Minor
Found in src/Plus/ReadMe.js - About 1 hr to fix

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

function Module(Q, _, Licenses, PackageJSON, Logger, Print) {

    /**
     * @readme plugins.License
     *
Severity: Minor
Found in src/Plus/Writers/License.js - About 1 hr to fix

Function Module has a Cognitive Complexity of 14 (exceeds 5 allowed). Consider refactoring.
Open

function Module(_) {

    /**
     * @memberof Plus.Collections
     * @constructor
Severity: Minor
Found in src/Plus/Collections/Arrays.js - About 1 hr 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 Module has a Cognitive Complexity of 14 (exceeds 5 allowed). Consider refactoring.
Open

function Module(Markdown) {

    /**
     * Sections are used to pre-define the structure of the Markdown document. These objects define both the
     * tree hierarchy and creation order for each section.
Severity: Minor
Found in src/Plus/Engine/Section.js - About 1 hr 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 Module has 42 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function Module(module, path, fs, _, Similarity, Logger, Strings, LicenseTypes) {

    /**
     * @memberof Plus.Services
     * @constructor
Severity: Minor
Found in src/Plus/Services/Licenses.js - About 1 hr to fix

Function Module has 40 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function Module(Q, _, Arrays) {

    /**
     * An instance of this class is created for each filter that is loaded. The responsibility of this class is to
     * manage the values that will be injected into the filter hook function. These are passed as extra pamaters to
Severity: Minor
Found in src/Plus/Engine/Filter.js - About 1 hr to fix

Function Module has 38 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function Module(module, path, fs) {

    /**
     * @memberof Plus.Services
     * @param {string} fileName
Severity: Minor
Found in src/Plus/Services/PackageJSON.js - About 1 hr to fix
Severity
Category
Status
Source
Language