IntegerMan/angularIF

View on GitHub

Showing 715 of 1,099 total issues

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

var __param = (this && this.__param) || function (paramIndex, decorator) {
    return function (target, key) { decorator(target, key, paramIndex); }
};
Severity: Major
Found in src/assets/primeng/components/menu/menu.js and 8 other locations - About 30 mins to fix
src/assets/primeng/components/contextmenu/contextmenu.js on lines 11..13
src/assets/primeng/components/datatable/datatable.js on lines 11..13
src/assets/primeng/components/growl/growl.js on lines 11..13
src/assets/primeng/components/messages/messages.js on lines 11..13
src/assets/primeng/components/organizationchart/organizationchart.js on lines 11..13
src/assets/primeng/components/slidemenu/slidemenu.js on lines 11..13
src/assets/primeng/components/tree/tree.js on lines 11..13
src/assets/primeng/components/treetable/treetable.js on lines 11..13

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

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

var __param = (this && this.__param) || function (paramIndex, decorator) {
    return function (target, key) { decorator(target, key, paramIndex); }
};
Severity: Major
Found in src/assets/primeng/components/messages/messages.js and 8 other locations - About 30 mins to fix
src/assets/primeng/components/contextmenu/contextmenu.js on lines 11..13
src/assets/primeng/components/datatable/datatable.js on lines 11..13
src/assets/primeng/components/growl/growl.js on lines 11..13
src/assets/primeng/components/menu/menu.js on lines 11..13
src/assets/primeng/components/organizationchart/organizationchart.js on lines 11..13
src/assets/primeng/components/slidemenu/slidemenu.js on lines 11..13
src/assets/primeng/components/tree/tree.js on lines 11..13
src/assets/primeng/components/treetable/treetable.js on lines 11..13

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

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

var __param = (this && this.__param) || function (paramIndex, decorator) {
    return function (target, key) { decorator(target, key, paramIndex); }
};
Severity: Major
Found in src/assets/primeng/components/treetable/treetable.js and 8 other locations - About 30 mins to fix
src/assets/primeng/components/contextmenu/contextmenu.js on lines 11..13
src/assets/primeng/components/datatable/datatable.js on lines 11..13
src/assets/primeng/components/growl/growl.js on lines 11..13
src/assets/primeng/components/menu/menu.js on lines 11..13
src/assets/primeng/components/messages/messages.js on lines 11..13
src/assets/primeng/components/organizationchart/organizationchart.js on lines 11..13
src/assets/primeng/components/slidemenu/slidemenu.js on lines 11..13
src/assets/primeng/components/tree/tree.js on lines 11..13

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

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

var __param = (this && this.__param) || function (paramIndex, decorator) {
    return function (target, key) { decorator(target, key, paramIndex); }
};
src/assets/primeng/components/contextmenu/contextmenu.js on lines 11..13
src/assets/primeng/components/datatable/datatable.js on lines 11..13
src/assets/primeng/components/growl/growl.js on lines 11..13
src/assets/primeng/components/menu/menu.js on lines 11..13
src/assets/primeng/components/messages/messages.js on lines 11..13
src/assets/primeng/components/slidemenu/slidemenu.js on lines 11..13
src/assets/primeng/components/tree/tree.js on lines 11..13
src/assets/primeng/components/treetable/treetable.js on lines 11..13

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

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

var __param = (this && this.__param) || function (paramIndex, decorator) {
    return function (target, key) { decorator(target, key, paramIndex); }
};
Severity: Major
Found in src/assets/primeng/components/growl/growl.js and 8 other locations - About 30 mins to fix
src/assets/primeng/components/contextmenu/contextmenu.js on lines 11..13
src/assets/primeng/components/datatable/datatable.js on lines 11..13
src/assets/primeng/components/menu/menu.js on lines 11..13
src/assets/primeng/components/messages/messages.js on lines 11..13
src/assets/primeng/components/organizationchart/organizationchart.js on lines 11..13
src/assets/primeng/components/slidemenu/slidemenu.js on lines 11..13
src/assets/primeng/components/tree/tree.js on lines 11..13
src/assets/primeng/components/treetable/treetable.js on lines 11..13

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

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

var __param = (this && this.__param) || function (paramIndex, decorator) {
    return function (target, key) { decorator(target, key, paramIndex); }
};
Severity: Major
Found in src/assets/primeng/components/contextmenu/contextmenu.js and 8 other locations - About 30 mins to fix
src/assets/primeng/components/datatable/datatable.js on lines 11..13
src/assets/primeng/components/growl/growl.js on lines 11..13
src/assets/primeng/components/menu/menu.js on lines 11..13
src/assets/primeng/components/messages/messages.js on lines 11..13
src/assets/primeng/components/organizationchart/organizationchart.js on lines 11..13
src/assets/primeng/components/slidemenu/slidemenu.js on lines 11..13
src/assets/primeng/components/tree/tree.js on lines 11..13
src/assets/primeng/components/treetable/treetable.js on lines 11..13

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

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

ColumnBodyTemplateLoader = __decorate([
    core_2.Component({
        selector: 'p-columnBodyTemplateLoader',
        template: ""
    }),
Severity: Major
Found in src/assets/primeng/components/common/shared.js and 12 other locations - About 30 mins to fix
src/assets/primeng/components/accordion/accordion.js on lines 81..87
src/assets/primeng/components/chart/chart.js on lines 106..112
src/assets/primeng/components/common/shared.js on lines 351..357
src/assets/primeng/components/common/shared.js on lines 377..383
src/assets/primeng/components/common/shared.js on lines 403..409
src/assets/primeng/components/common/shared.js on lines 439..445
src/assets/primeng/components/common/shared.js on lines 472..478
src/assets/primeng/components/datatable/datatable.js on lines 104..110
src/assets/primeng/components/organizationchart/organizationchart.js on lines 43..49
src/assets/primeng/components/tabview/tabview.js on lines 147..153
src/assets/primeng/components/tabview/tabview.js on lines 317..323
src/assets/primeng/components/tree/tree.js on lines 43..49

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

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

TabView = __decorate([
    core_1.Component({
        selector: 'p-tabView',
        template: "\n        <div [ngClass]=\"'ui-tabview ui-widget ui-widget-content ui-corner-all ui-tabview-' + orientation\" [ngStyle]=\"style\" [class]=\"styleClass\">\n            <ul p-tabViewNav role=\"tablist\" *ngIf=\"orientation!='bottom'\" [tabs]=\"tabs\" [orientation]=\"orientation\" \n                (onTabClick)=\"open($event.originalEvent, $event.tab)\" (onTabCloseClick)=\"close($event.originalEvent, $event.tab)\"></ul>\n            <div class=\"ui-tabview-panels\">\n                <ng-content></ng-content>\n            </div>\n            <ul p-tabViewNav role=\"tablist\" *ngIf=\"orientation=='bottom'\" [tabs]=\"tabs\" [orientation]=\"orientation\"\n                (onTabClick)=\"open($event.originalEvent, $event.tab)\" (onTabCloseClick)=\"close($event.originalEvent, $event.tab)\"></ul>\n        </div>\n    ",
    }),
Severity: Major
Found in src/assets/primeng/components/tabview/tabview.js and 12 other locations - About 30 mins to fix
src/assets/primeng/components/accordion/accordion.js on lines 81..87
src/assets/primeng/components/chart/chart.js on lines 106..112
src/assets/primeng/components/common/shared.js on lines 325..331
src/assets/primeng/components/common/shared.js on lines 351..357
src/assets/primeng/components/common/shared.js on lines 377..383
src/assets/primeng/components/common/shared.js on lines 403..409
src/assets/primeng/components/common/shared.js on lines 439..445
src/assets/primeng/components/common/shared.js on lines 472..478
src/assets/primeng/components/datatable/datatable.js on lines 104..110
src/assets/primeng/components/organizationchart/organizationchart.js on lines 43..49
src/assets/primeng/components/tabview/tabview.js on lines 147..153
src/assets/primeng/components/tree/tree.js on lines 43..49

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

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

TemplateLoader = __decorate([
    core_2.Component({
        selector: 'p-templateLoader',
        template: ""
    }),
Severity: Major
Found in src/assets/primeng/components/common/shared.js and 12 other locations - About 30 mins to fix
src/assets/primeng/components/accordion/accordion.js on lines 81..87
src/assets/primeng/components/chart/chart.js on lines 106..112
src/assets/primeng/components/common/shared.js on lines 325..331
src/assets/primeng/components/common/shared.js on lines 351..357
src/assets/primeng/components/common/shared.js on lines 377..383
src/assets/primeng/components/common/shared.js on lines 403..409
src/assets/primeng/components/common/shared.js on lines 439..445
src/assets/primeng/components/datatable/datatable.js on lines 104..110
src/assets/primeng/components/organizationchart/organizationchart.js on lines 43..49
src/assets/primeng/components/tabview/tabview.js on lines 147..153
src/assets/primeng/components/tabview/tabview.js on lines 317..323
src/assets/primeng/components/tree/tree.js on lines 43..49

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

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

Accordion = __decorate([
    core_1.Component({
        selector: 'p-accordion',
        template: "\n        <div [ngClass]=\"'ui-accordion ui-widget ui-helper-reset'\" [ngStyle]=\"style\" [class]=\"styleClass\">\n            <ng-content></ng-content>\n        </div>\n    ",
    }),
Severity: Major
Found in src/assets/primeng/components/accordion/accordion.js and 12 other locations - About 30 mins to fix
src/assets/primeng/components/chart/chart.js on lines 106..112
src/assets/primeng/components/common/shared.js on lines 325..331
src/assets/primeng/components/common/shared.js on lines 351..357
src/assets/primeng/components/common/shared.js on lines 377..383
src/assets/primeng/components/common/shared.js on lines 403..409
src/assets/primeng/components/common/shared.js on lines 439..445
src/assets/primeng/components/common/shared.js on lines 472..478
src/assets/primeng/components/datatable/datatable.js on lines 104..110
src/assets/primeng/components/organizationchart/organizationchart.js on lines 43..49
src/assets/primeng/components/tabview/tabview.js on lines 147..153
src/assets/primeng/components/tabview/tabview.js on lines 317..323
src/assets/primeng/components/tree/tree.js on lines 43..49

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

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

ColumnHeaderTemplateLoader = __decorate([
    core_2.Component({
        selector: 'p-columnHeaderTemplateLoader',
        template: ""
    }),
Severity: Major
Found in src/assets/primeng/components/common/shared.js and 12 other locations - About 30 mins to fix
src/assets/primeng/components/accordion/accordion.js on lines 81..87
src/assets/primeng/components/chart/chart.js on lines 106..112
src/assets/primeng/components/common/shared.js on lines 325..331
src/assets/primeng/components/common/shared.js on lines 377..383
src/assets/primeng/components/common/shared.js on lines 403..409
src/assets/primeng/components/common/shared.js on lines 439..445
src/assets/primeng/components/common/shared.js on lines 472..478
src/assets/primeng/components/datatable/datatable.js on lines 104..110
src/assets/primeng/components/organizationchart/organizationchart.js on lines 43..49
src/assets/primeng/components/tabview/tabview.js on lines 147..153
src/assets/primeng/components/tabview/tabview.js on lines 317..323
src/assets/primeng/components/tree/tree.js on lines 43..49

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

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

UIChart = __decorate([
    core_1.Component({
        selector: 'p-chart',
        template: "\n        <div>\n            <canvas [attr.width]=\"width\" [attr.height]=\"height\" (click)=\"onCanvasClick($event)\"></canvas>\n        </div>\n    "
    }),
Severity: Major
Found in src/assets/primeng/components/chart/chart.js and 12 other locations - About 30 mins to fix
src/assets/primeng/components/accordion/accordion.js on lines 81..87
src/assets/primeng/components/common/shared.js on lines 325..331
src/assets/primeng/components/common/shared.js on lines 351..357
src/assets/primeng/components/common/shared.js on lines 377..383
src/assets/primeng/components/common/shared.js on lines 403..409
src/assets/primeng/components/common/shared.js on lines 439..445
src/assets/primeng/components/common/shared.js on lines 472..478
src/assets/primeng/components/datatable/datatable.js on lines 104..110
src/assets/primeng/components/organizationchart/organizationchart.js on lines 43..49
src/assets/primeng/components/tabview/tabview.js on lines 147..153
src/assets/primeng/components/tabview/tabview.js on lines 317..323
src/assets/primeng/components/tree/tree.js on lines 43..49

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

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

OrganizationChartNodeTemplateLoader = __decorate([
    core_1.Component({
        selector: 'p-organizationChartNodeTemplateLoader',
        template: ""
    }),
src/assets/primeng/components/accordion/accordion.js on lines 81..87
src/assets/primeng/components/chart/chart.js on lines 106..112
src/assets/primeng/components/common/shared.js on lines 325..331
src/assets/primeng/components/common/shared.js on lines 351..357
src/assets/primeng/components/common/shared.js on lines 377..383
src/assets/primeng/components/common/shared.js on lines 403..409
src/assets/primeng/components/common/shared.js on lines 439..445
src/assets/primeng/components/common/shared.js on lines 472..478
src/assets/primeng/components/datatable/datatable.js on lines 104..110
src/assets/primeng/components/tabview/tabview.js on lines 147..153
src/assets/primeng/components/tabview/tabview.js on lines 317..323
src/assets/primeng/components/tree/tree.js on lines 43..49

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

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

TabPanel = __decorate([
    core_1.Component({
        selector: 'p-tabPanel',
        template: "\n        <div class=\"ui-tabview-panel ui-widget-content\" [style.display]=\"selected ? 'block' : 'none'\" \n            role=\"tabpanel\" [attr.aria-hidden]=\"!selected\" *ngIf=\"!closed\">\n            <ng-content></ng-content>\n            <p-templateLoader [template]=\"contentTemplate\" *ngIf=\"contentTemplate&&(cache ? loaded : selected)\"></p-templateLoader>\n        </div>\n    "
    }),
Severity: Major
Found in src/assets/primeng/components/tabview/tabview.js and 12 other locations - About 30 mins to fix
src/assets/primeng/components/accordion/accordion.js on lines 81..87
src/assets/primeng/components/chart/chart.js on lines 106..112
src/assets/primeng/components/common/shared.js on lines 325..331
src/assets/primeng/components/common/shared.js on lines 351..357
src/assets/primeng/components/common/shared.js on lines 377..383
src/assets/primeng/components/common/shared.js on lines 403..409
src/assets/primeng/components/common/shared.js on lines 439..445
src/assets/primeng/components/common/shared.js on lines 472..478
src/assets/primeng/components/datatable/datatable.js on lines 104..110
src/assets/primeng/components/organizationchart/organizationchart.js on lines 43..49
src/assets/primeng/components/tabview/tabview.js on lines 317..323
src/assets/primeng/components/tree/tree.js on lines 43..49

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

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

TreeNodeTemplateLoader = __decorate([
    core_1.Component({
        selector: 'p-treeNodeTemplateLoader',
        template: ""
    }),
Severity: Major
Found in src/assets/primeng/components/tree/tree.js and 12 other locations - About 30 mins to fix
src/assets/primeng/components/accordion/accordion.js on lines 81..87
src/assets/primeng/components/chart/chart.js on lines 106..112
src/assets/primeng/components/common/shared.js on lines 325..331
src/assets/primeng/components/common/shared.js on lines 351..357
src/assets/primeng/components/common/shared.js on lines 377..383
src/assets/primeng/components/common/shared.js on lines 403..409
src/assets/primeng/components/common/shared.js on lines 439..445
src/assets/primeng/components/common/shared.js on lines 472..478
src/assets/primeng/components/datatable/datatable.js on lines 104..110
src/assets/primeng/components/organizationchart/organizationchart.js on lines 43..49
src/assets/primeng/components/tabview/tabview.js on lines 147..153
src/assets/primeng/components/tabview/tabview.js on lines 317..323

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

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

RowExpansionLoader = __decorate([
    core_1.Component({
        selector: 'p-rowExpansionLoader',
        template: ""
    }),
Severity: Major
Found in src/assets/primeng/components/datatable/datatable.js and 12 other locations - About 30 mins to fix
src/assets/primeng/components/accordion/accordion.js on lines 81..87
src/assets/primeng/components/chart/chart.js on lines 106..112
src/assets/primeng/components/common/shared.js on lines 325..331
src/assets/primeng/components/common/shared.js on lines 351..357
src/assets/primeng/components/common/shared.js on lines 377..383
src/assets/primeng/components/common/shared.js on lines 403..409
src/assets/primeng/components/common/shared.js on lines 439..445
src/assets/primeng/components/common/shared.js on lines 472..478
src/assets/primeng/components/organizationchart/organizationchart.js on lines 43..49
src/assets/primeng/components/tabview/tabview.js on lines 147..153
src/assets/primeng/components/tabview/tabview.js on lines 317..323
src/assets/primeng/components/tree/tree.js on lines 43..49

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

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

ColumnFooterTemplateLoader = __decorate([
    core_2.Component({
        selector: 'p-columnFooterTemplateLoader',
        template: ""
    }),
Severity: Major
Found in src/assets/primeng/components/common/shared.js and 12 other locations - About 30 mins to fix
src/assets/primeng/components/accordion/accordion.js on lines 81..87
src/assets/primeng/components/chart/chart.js on lines 106..112
src/assets/primeng/components/common/shared.js on lines 325..331
src/assets/primeng/components/common/shared.js on lines 351..357
src/assets/primeng/components/common/shared.js on lines 403..409
src/assets/primeng/components/common/shared.js on lines 439..445
src/assets/primeng/components/common/shared.js on lines 472..478
src/assets/primeng/components/datatable/datatable.js on lines 104..110
src/assets/primeng/components/organizationchart/organizationchart.js on lines 43..49
src/assets/primeng/components/tabview/tabview.js on lines 147..153
src/assets/primeng/components/tabview/tabview.js on lines 317..323
src/assets/primeng/components/tree/tree.js on lines 43..49

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

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

ColumnFilterTemplateLoader = __decorate([
    core_2.Component({
        selector: 'p-columnFilterTemplateLoader',
        template: ""
    }),
Severity: Major
Found in src/assets/primeng/components/common/shared.js and 12 other locations - About 30 mins to fix
src/assets/primeng/components/accordion/accordion.js on lines 81..87
src/assets/primeng/components/chart/chart.js on lines 106..112
src/assets/primeng/components/common/shared.js on lines 325..331
src/assets/primeng/components/common/shared.js on lines 351..357
src/assets/primeng/components/common/shared.js on lines 377..383
src/assets/primeng/components/common/shared.js on lines 439..445
src/assets/primeng/components/common/shared.js on lines 472..478
src/assets/primeng/components/datatable/datatable.js on lines 104..110
src/assets/primeng/components/organizationchart/organizationchart.js on lines 43..49
src/assets/primeng/components/tabview/tabview.js on lines 147..153
src/assets/primeng/components/tabview/tabview.js on lines 317..323
src/assets/primeng/components/tree/tree.js on lines 43..49

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

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

    Terminal.prototype.ngOnDestroy = function () {
        if (this.subscription) {
            this.subscription.unsubscribe();
        }
    };
Severity: Major
Found in src/assets/primeng/components/terminal/terminal.js and 3 other locations - About 30 mins to fix
src/assets/primeng/components/chart/chart.js on lines 56..60
src/assets/primeng/components/chart/chart.js on lines 61..65
src/assets/primeng/components/messages/messages.js on lines 80..84

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

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

    DataScroller.prototype.isEmpty = function () {
        return !this.dataToRender || (this.dataToRender.length == 0);
    };
Severity: Major
Found in src/assets/primeng/components/datascroller/datascroller.js and 3 other locations - About 30 mins to fix
src/assets/primeng/components/datagrid/datagrid.js on lines 118..120
src/assets/primeng/components/datalist/datalist.js on lines 118..120
src/assets/primeng/components/datatable/datatable.js on lines 1749..1751

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

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

Severity
Category
Status
Source
Language