nexxtway/react-rainbow

View on GitHub
library/exampleComponents/Icons/application.js

Summary

Maintainability
A
3 hrs
Test Coverage

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

const Application = props => {
    const { className, style } = props;
    return (
        <svg
            className={className}
Severity: Minor
Found in library/exampleComponents/Icons/application.js - About 2 hrs to fix

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

                                <g id="Group" transform="translate(1.113351, 0.000000)" fill="#E20460">
                                    <path d="M3.80434783,-3.41632003e-15 L0.808019004,-3.41632003e-15 C0.362018927,-3.41632003e-15 0.00044990882,0.361569018 0.00044990882,0.807569095 L0.00044990882,1.89167628 L2.3061834,2.64360783 L4.61176696,1.89167628 L4.61176696,0.807569095 C4.61191692,0.361569018 4.25034794,-3.55271368e-15 3.80434783,-3.41632003e-15 Z" />
                                    <path d="M13.6253479,0 L16.6216767,0 C17.0676768,0 17.4292458,0.361569018 17.4292458,0.807569095 L17.4292458,1.89167628 L15.1235124,2.64360783 L12.8177788,1.89152629 L12.8177788,0.807569095 C12.8177788,0.361569018 13.1793478,0 13.6253479,0 Z" />
                                    <path d="M10.2130123,0 L7.21668344,0 C6.77068337,0 6.40911435,0.361569018 6.40911435,0.807569095 L6.40911435,1.89167628 L8.71484787,2.64360783 L11.0204314,1.89152629 L11.0204314,0.807569095 C11.0204314,0.361569018 10.6590124,0 10.2130123,0 Z" />
                                </g>
    Severity: Major
    Found in library/exampleComponents/Icons/application.js and 5 other locations - About 1 hr to fix
    library/exampleComponents/Icons/photographer.js on lines 49..57
    library/pages/components/FeatureList/images/testing.js on lines 129..133
    src/components/PhoneInput/flags/SaintBarthelemy.js on lines 476..480
    src/components/PhoneInput/flags/SaintBarthelemy.js on lines 481..485
    src/components/PhoneInput/flags/SaintBarthelemy.js on lines 486..490

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

    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