spacekitcat/hackertextjs

View on GitHub

Showing 14 of 15 total issues

Similar blocks of code found in 2 locations. Consider refactoring.
Open

define('CoSinePhaseFrameRenderStrategy', [
  'ValidatingPropertyObject'
], ValidatingPropertyObject =>
  class CoSinePhaseFrameRenderStrategy {
    constructor(options) {
Severity: Major
Found in src/CoSinePhaseFrameRenderStrategy.js and 1 other location - About 3 days to fix
src/SinePhaseFrameRenderStrategy.js on lines 1..89

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 557.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

define('SinePhaseFrameRenderStrategy', [
  'ValidatingPropertyObject'
], ValidatingPropertyObject =>
  class SinePhaseFrameRenderStrategy {
    constructor(options) {
Severity: Major
Found in src/SinePhaseFrameRenderStrategy.js and 1 other location - About 3 days to fix
src/CoSinePhaseFrameRenderStrategy.js on lines 1..89

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 557.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 3 locations. Consider refactoring.
Open

  'Custom renderer, SinePhase smoke test' : function (client) {

    client
      .url('http://localhost:8000/examples/SinePhaseSmokeTest.html');

Severity: Major
Found in integration-tests/hacker-text-smoke-test.js and 2 other locations - About 2 days to fix
integration-tests/hacker-text-smoke-test.js on lines 13..56
integration-tests/hacker-text-smoke-test.js on lines 57..100

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 487.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 3 locations. Consider refactoring.
Open

  'Custom renderer, Randomized smoke test' : function (client) {

    client
      .url('http://localhost:8000/examples/RandomizedSmokeTest.html');

Severity: Major
Found in integration-tests/hacker-text-smoke-test.js and 2 other locations - About 2 days to fix
integration-tests/hacker-text-smoke-test.js on lines 13..56
integration-tests/hacker-text-smoke-test.js on lines 101..144

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 487.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 3 locations. Consider refactoring.
Open

  'Basic model smoke test' : function (client) {

    client
      .url('http://localhost:8000/examples/SimpleExampleOne.html');

Severity: Major
Found in integration-tests/hacker-text-smoke-test.js and 2 other locations - About 2 days to fix
integration-tests/hacker-text-smoke-test.js on lines 57..100
integration-tests/hacker-text-smoke-test.js on lines 101..144

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 487.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

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

    static assemble(widgetDescriptor) {
      if (widgetDescriptor === null || widgetDescriptor === undefined) {
        throw new Error('A widget descriptor must be provided.');
      }

Severity: Minor
Found in src/WidgetAssemblyDirector.js - About 1 hr to fix

    Identical blocks of code found in 2 locations. Consider refactoring.
    Open

      return (character) => {
        if (character === undefined) {
          throw new TypeError('No arguments provided. The character argument must be provided.');
        }
    
    
    Severity: Minor
    Found in src/WhiteSpaceSourceFilter.js and 1 other location - About 50 mins to fix
    src/LeetSourceFilter.js on lines 26..36

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 52.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Identical blocks of code found in 2 locations. Consider refactoring.
    Open

      return (character) => {
        if (character === undefined) {
          throw new TypeError('No arguments provided. The character argument must be provided.');
        }
    
    
    Severity: Minor
    Found in src/LeetSourceFilter.js and 1 other location - About 50 mins to fix
    src/WhiteSpaceSourceFilter.js on lines 29..39

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 52.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Identical blocks of code found in 2 locations. Consider refactoring.
    Open

        getOptionValue(key) {
          if (key === undefined || key === null) {
            throw new Error('An option key must be provided.');
          }
    
    
    Severity: Minor
    Found in src/VerticalSinePhaseFrameRenderStrategy.js and 1 other location - About 35 mins to fix
    src/FrameRenderer.js on lines 87..93

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 46.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Identical blocks of code found in 2 locations. Consider refactoring.
    Open

        getOptionValue(key) {
          if (key === undefined || key === null) {
            throw new Error('An option key must be provided.');
          }
    
    
    Severity: Minor
    Found in src/FrameRenderer.js and 1 other location - About 35 mins to fix
    src/VerticalSinePhaseFrameRenderStrategy.js on lines 74..80

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 46.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    TODO found
    Open

        // TODO: Refactor
    Severity: Minor
    Found in src/Widget.js by fixme

    TODO found
    Open

    // TODO: This could be broken up, but I can't find any good documentation on how.
    Severity: Minor
    Found in karma.conf.js by fixme

    TODO found
    Open

          <window_info id="TODO" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" />
    Severity: Minor
    Found in .idea/workspace.xml by fixme

    TODO found
    Open

          // TODO: This can be written more clearly.
    Severity: Minor
    Found in src/AnimationScheduler.js by fixme
    Severity
    Category
    Status
    Source
    Language