benchmarks/js-framwork-bench/src/Main.jsx

Summary

Maintainability
D
2 days
Test Coverage

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

  render() {
    return (
      <div className="container">
        <div className="jumbotron">
          <div className="row">
Severity: Major
Found in benchmarks/js-framwork-bench/src/Main.jsx - About 3 hrs to fix

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

      delete(id) {
        startMeasure("delete");
        this.state.store.delete(id);
        this.setState({ store: this.state.store });
      }
    Severity: Major
    Found in benchmarks/js-framwork-bench/src/Main.jsx and 1 other location - About 1 hr to fix
    benchmarks/js-framwork-bench/src/Main.jsx on lines 123..127

    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 60.

    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

      select(id) {
        startMeasure("select");
        this.state.store.select(id);
        this.setState({ store: this.state.store });
      }
    Severity: Major
    Found in benchmarks/js-framwork-bench/src/Main.jsx and 1 other location - About 1 hr to fix
    benchmarks/js-framwork-bench/src/Main.jsx on lines 128..132

    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 60.

    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 6 locations. Consider refactoring.
    Open

      run() {
        startMeasure("run");
        this.state.store.run();
        this.setState({ store: this.state.store });
      }
    Severity: Major
    Found in benchmarks/js-framwork-bench/src/Main.jsx and 5 other locations - About 1 hr to fix
    benchmarks/js-framwork-bench/src/Main.jsx on lines 113..117
    benchmarks/js-framwork-bench/src/Main.jsx on lines 118..122
    benchmarks/js-framwork-bench/src/Main.jsx on lines 133..137
    benchmarks/js-framwork-bench/src/Main.jsx on lines 138..142
    benchmarks/js-framwork-bench/src/Main.jsx on lines 143..147

    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 58.

    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 6 locations. Consider refactoring.
    Open

      swapRows() {
        startMeasure("swapRows");
        this.state.store.swapRows();
        this.setState({ store: this.state.store });
      }
    Severity: Major
    Found in benchmarks/js-framwork-bench/src/Main.jsx and 5 other locations - About 1 hr to fix
    benchmarks/js-framwork-bench/src/Main.jsx on lines 108..112
    benchmarks/js-framwork-bench/src/Main.jsx on lines 113..117
    benchmarks/js-framwork-bench/src/Main.jsx on lines 118..122
    benchmarks/js-framwork-bench/src/Main.jsx on lines 133..137
    benchmarks/js-framwork-bench/src/Main.jsx on lines 138..142

    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 58.

    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 6 locations. Consider refactoring.
    Open

      add() {
        startMeasure("add");
        this.state.store.add();
        this.setState({ store: this.state.store });
      }
    Severity: Major
    Found in benchmarks/js-framwork-bench/src/Main.jsx and 5 other locations - About 1 hr to fix
    benchmarks/js-framwork-bench/src/Main.jsx on lines 108..112
    benchmarks/js-framwork-bench/src/Main.jsx on lines 118..122
    benchmarks/js-framwork-bench/src/Main.jsx on lines 133..137
    benchmarks/js-framwork-bench/src/Main.jsx on lines 138..142
    benchmarks/js-framwork-bench/src/Main.jsx on lines 143..147

    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 58.

    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 6 locations. Consider refactoring.
    Open

      clear() {
        startMeasure("clear");
        this.state.store.clear();
        this.setState({ store: this.state.store });
      }
    Severity: Major
    Found in benchmarks/js-framwork-bench/src/Main.jsx and 5 other locations - About 1 hr to fix
    benchmarks/js-framwork-bench/src/Main.jsx on lines 108..112
    benchmarks/js-framwork-bench/src/Main.jsx on lines 113..117
    benchmarks/js-framwork-bench/src/Main.jsx on lines 118..122
    benchmarks/js-framwork-bench/src/Main.jsx on lines 133..137
    benchmarks/js-framwork-bench/src/Main.jsx on lines 143..147

    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 58.

    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 6 locations. Consider refactoring.
    Open

      update() {
        startMeasure("update");
        this.state.store.update();
        this.setState({ store: this.state.store });
      }
    Severity: Major
    Found in benchmarks/js-framwork-bench/src/Main.jsx and 5 other locations - About 1 hr to fix
    benchmarks/js-framwork-bench/src/Main.jsx on lines 108..112
    benchmarks/js-framwork-bench/src/Main.jsx on lines 113..117
    benchmarks/js-framwork-bench/src/Main.jsx on lines 133..137
    benchmarks/js-framwork-bench/src/Main.jsx on lines 138..142
    benchmarks/js-framwork-bench/src/Main.jsx on lines 143..147

    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 58.

    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 6 locations. Consider refactoring.
    Open

      runLots() {
        startMeasure("runLots");
        this.state.store.runLots();
        this.setState({ store: this.state.store });
      }
    Severity: Major
    Found in benchmarks/js-framwork-bench/src/Main.jsx and 5 other locations - About 1 hr to fix
    benchmarks/js-framwork-bench/src/Main.jsx on lines 108..112
    benchmarks/js-framwork-bench/src/Main.jsx on lines 113..117
    benchmarks/js-framwork-bench/src/Main.jsx on lines 118..122
    benchmarks/js-framwork-bench/src/Main.jsx on lines 138..142
    benchmarks/js-framwork-bench/src/Main.jsx on lines 143..147

    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 58.

    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 6 locations. Consider refactoring.
    Open

                    <div className="col-sm-6 smallpad">
                      <button
                        type="button"
                        className="btn btn-primary btn-block"
                        id="runlots"
    Severity: Major
    Found in benchmarks/js-framwork-bench/src/Main.jsx and 5 other locations - About 1 hr to fix
    benchmarks/js-framwork-bench/src/Main.jsx on lines 158..167
    benchmarks/js-framwork-bench/src/Main.jsx on lines 178..187
    benchmarks/js-framwork-bench/src/Main.jsx on lines 188..197
    benchmarks/js-framwork-bench/src/Main.jsx on lines 198..207
    benchmarks/js-framwork-bench/src/Main.jsx on lines 208..217

    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 56.

    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 6 locations. Consider refactoring.
    Open

                    <div className="col-sm-6 smallpad">
                      <button
                        type="button"
                        className="btn btn-primary btn-block"
                        id="add"
    Severity: Major
    Found in benchmarks/js-framwork-bench/src/Main.jsx and 5 other locations - About 1 hr to fix
    benchmarks/js-framwork-bench/src/Main.jsx on lines 158..167
    benchmarks/js-framwork-bench/src/Main.jsx on lines 168..177
    benchmarks/js-framwork-bench/src/Main.jsx on lines 188..197
    benchmarks/js-framwork-bench/src/Main.jsx on lines 198..207
    benchmarks/js-framwork-bench/src/Main.jsx on lines 208..217

    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 56.

    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 6 locations. Consider refactoring.
    Open

                    <div className="col-sm-6 smallpad">
                      <button
                        type="button"
                        className="btn btn-primary btn-block"
                        id="run"
    Severity: Major
    Found in benchmarks/js-framwork-bench/src/Main.jsx and 5 other locations - About 1 hr to fix
    benchmarks/js-framwork-bench/src/Main.jsx on lines 168..177
    benchmarks/js-framwork-bench/src/Main.jsx on lines 178..187
    benchmarks/js-framwork-bench/src/Main.jsx on lines 188..197
    benchmarks/js-framwork-bench/src/Main.jsx on lines 198..207
    benchmarks/js-framwork-bench/src/Main.jsx on lines 208..217

    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 56.

    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 6 locations. Consider refactoring.
    Open

                    <div className="col-sm-6 smallpad">
                      <button
                        type="button"
                        className="btn btn-primary btn-block"
                        id="update"
    Severity: Major
    Found in benchmarks/js-framwork-bench/src/Main.jsx and 5 other locations - About 1 hr to fix
    benchmarks/js-framwork-bench/src/Main.jsx on lines 158..167
    benchmarks/js-framwork-bench/src/Main.jsx on lines 168..177
    benchmarks/js-framwork-bench/src/Main.jsx on lines 178..187
    benchmarks/js-framwork-bench/src/Main.jsx on lines 198..207
    benchmarks/js-framwork-bench/src/Main.jsx on lines 208..217

    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 56.

    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 6 locations. Consider refactoring.
    Open

                    <div className="col-sm-6 smallpad">
                      <button
                        type="button"
                        className="btn btn-primary btn-block"
                        id="swaprows"
    Severity: Major
    Found in benchmarks/js-framwork-bench/src/Main.jsx and 5 other locations - About 1 hr to fix
    benchmarks/js-framwork-bench/src/Main.jsx on lines 158..167
    benchmarks/js-framwork-bench/src/Main.jsx on lines 168..177
    benchmarks/js-framwork-bench/src/Main.jsx on lines 178..187
    benchmarks/js-framwork-bench/src/Main.jsx on lines 188..197
    benchmarks/js-framwork-bench/src/Main.jsx on lines 198..207

    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 56.

    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 6 locations. Consider refactoring.
    Open

                    <div className="col-sm-6 smallpad">
                      <button
                        type="button"
                        className="btn btn-primary btn-block"
                        id="clear"
    Severity: Major
    Found in benchmarks/js-framwork-bench/src/Main.jsx and 5 other locations - About 1 hr to fix
    benchmarks/js-framwork-bench/src/Main.jsx on lines 158..167
    benchmarks/js-framwork-bench/src/Main.jsx on lines 168..177
    benchmarks/js-framwork-bench/src/Main.jsx on lines 178..187
    benchmarks/js-framwork-bench/src/Main.jsx on lines 188..197
    benchmarks/js-framwork-bench/src/Main.jsx on lines 208..217

    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 56.

    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

    There are no issues that match your filters.

    Category
    Status