cosmas28/toDo-ui

View on GitHub
components/NavBar.tsx

Summary

Maintainability
A
0 mins
Test Coverage

Showing 0 of 5 total issues

Function render has 48 lines of code (exceeds 25 allowed). Consider refactoring.
Invalid

render(): JSX.Element {
const { showMobileMenu, activeMenu } = this.props.store;
return (
<Nav>
<Link href="/">
Severity: Minor
Found in components/NavBar.tsx - About 1 hr to fix

    Similar blocks of code found in 4 locations. Consider refactoring.
    Invalid

    <MenuLink
    onClick={this.handleLinkClick('Goals')}
    active={activeMenu === 'Goals' ? true : false}
    showMobileMenu={showMobileMenu}
    >
    Severity: Major
    Found in components/NavBar.tsx and 3 other locations - About 50 mins to fix
    components/NavBar.tsx on lines 115..121
    components/NavBar.tsx on lines 130..136
    components/NavBar.tsx on lines 137..143

    Similar blocks of code found in 4 locations. Consider refactoring.
    Invalid

    <MenuLink
    onClick={this.handleLinkClick('To-Do')}
    active={activeMenu === 'To-Do' ? true : false}
    showMobileMenu={showMobileMenu}
    >
    Severity: Major
    Found in components/NavBar.tsx and 3 other locations - About 50 mins to fix
    components/NavBar.tsx on lines 123..129
    components/NavBar.tsx on lines 130..136
    components/NavBar.tsx on lines 137..143

    Similar blocks of code found in 4 locations. Consider refactoring.
    Invalid

    <MenuLink
    onClick={this.handleLinkClick('Notes')}
    active={activeMenu === 'Notes' ? true : false}
    showMobileMenu={showMobileMenu}
    >
    Severity: Major
    Found in components/NavBar.tsx and 3 other locations - About 50 mins to fix
    components/NavBar.tsx on lines 115..121
    components/NavBar.tsx on lines 123..129
    components/NavBar.tsx on lines 137..143

    Similar blocks of code found in 4 locations. Consider refactoring.
    Invalid

    <MenuLink
    onClick={this.handleLinkClick('Routines')}
    active={activeMenu === 'Routines' ? true : false}
    showMobileMenu={showMobileMenu}
    >
    Severity: Major
    Found in components/NavBar.tsx and 3 other locations - About 50 mins to fix
    components/NavBar.tsx on lines 115..121
    components/NavBar.tsx on lines 123..129
    components/NavBar.tsx on lines 130..136

    There are no issues that match your filters.

    Category
    Status