gwcuva/gwc-website

View on GitHub

Showing 372 of 372 total issues

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

            {dates.length>0 && 
              day1events.map((event, index) =>
                <Activity key={index} starttime={event.startTime} endtime={event.endTime} name={event.eventName} link={event.link} linkname={event.linkText} detail={event.description} />
              )
            }
Severity: Major
Found in src/components/GirlsHooHack2022/Schedule/Schedule.tsx and 3 other locations - About 3 hrs to fix
src/components/GirlsHooHack2022/Schedule/Schedule.tsx on lines 184..188
src/components/GirlsHooHack2023/Schedule/Schedule.tsx on lines 177..181
src/components/GirlsHooHack2023/Schedule/Schedule.tsx on lines 185..189

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

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

            {dates.length>1 &&
              day2events.map((event, index) =>
                <Activity key={index} starttime={event.startTime} endtime={event.endTime} name={event.eventName} link={event.link} linkname={event.linkText} detail={event.description} />
              )
            }
Severity: Major
Found in src/components/GirlsHooHack2022/Schedule/Schedule.tsx and 3 other locations - About 3 hrs to fix
src/components/GirlsHooHack2022/Schedule/Schedule.tsx on lines 176..180
src/components/GirlsHooHack2023/Schedule/Schedule.tsx on lines 177..181
src/components/GirlsHooHack2023/Schedule/Schedule.tsx on lines 185..189

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

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

            {dates.length>0 && 
              day1events.map((event, index) =>
                <Activity key={index} starttime={event.startTime} endtime={event.endTime} name={event.eventName} link={event.link} linkname={event.linkText} detail={event.description} />
              )
            }
Severity: Major
Found in src/components/GirlsHooHack2023/Schedule/Schedule.tsx and 3 other locations - About 3 hrs to fix
src/components/GirlsHooHack2022/Schedule/Schedule.tsx on lines 176..180
src/components/GirlsHooHack2022/Schedule/Schedule.tsx on lines 184..188
src/components/GirlsHooHack2023/Schedule/Schedule.tsx on lines 185..189

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

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

                  {prizes.length===0 ? <p className='ml-3'>Coming Soon!</p> :
                  prizes.map((prize) => 
                    <PrizeItem key={prize.id} name={prize.prizeName} object={prize.prizeObject} detail={prize.description} ></PrizeItem>)}
Severity: Major
Found in src/components/GirlsHooHack2023/Prizes/Prizes.tsx and 1 other location - About 3 hrs to fix
src/components/GirlsHooHack2022/Prizes/Prizes.tsx on lines 46..48

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

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

                  {prizes.length===0 ? <p className='ml-3'>Coming Soon!</p> :
                  prizes.map((prize) => 
                    <PrizeItem key={prize.id} name={prize.prizeName} object={prize.prizeObject} detail={prize.description} ></PrizeItem>)}
Severity: Major
Found in src/components/GirlsHooHack2022/Prizes/Prizes.tsx and 1 other location - About 3 hrs to fix
src/components/GirlsHooHack2023/Prizes/Prizes.tsx on lines 49..51

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

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 Team has 79 lines of code (exceeds 25 allowed). Consider refactoring.
Open

function Team(props: Props) {
  const [team, setTeam] = useState([{'id': '', 'name': '', 'position': '', 'academicYear': '', 'headshot': {'url': ''}, 'linkedin': ''}]);
  const [academicYear, setAcademicYear] = useState('');
  const [boardYears, setBoardYears] = useState(['']);

Severity: Major
Found in src/components/Main/Team/Team.tsx - About 3 hrs to fix

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

                    {prizes.length===0 ? <p>Coming Soon!</p> :
                    prizes.map((prize) => 
                    <PrizeItem key={prize.id} name={prize.prizeName} object={prize.prizeObject} detail={prize.description} ></PrizeItem>)}
    Severity: Major
    Found in src/components/GirlsHooHack2022/Prizes/Prizes.tsx and 1 other location - About 2 hrs to fix
    src/components/GirlsHooHack2023/Prizes/Prizes.tsx on lines 40..42

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

    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

                    {prizes.length===0 ? <p>Coming Soon!</p> :
                    prizes.map((prize) => 
                    <PrizeItem key={prize.id} name={prize.prizeName} object={prize.prizeObject} detail={prize.description} ></PrizeItem>)}
    Severity: Major
    Found in src/components/GirlsHooHack2023/Prizes/Prizes.tsx and 1 other location - About 2 hrs to fix
    src/components/GirlsHooHack2022/Prizes/Prizes.tsx on lines 38..40

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

    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

            <Row xs={12} className="pb-0">
              <Col xs={2}></Col>
              <Col xs={5}><h1 className={isMobile ? "text-white ml-n3":"text-white"}> WE'RE</h1></Col>
            </Row>
    Severity: Major
    Found in src/components/Main/Header/Header.tsx and 1 other location - About 2 hrs to fix
    src/components/Main/Header/Header.tsx on lines 38..41

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

    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

            <Row xs={3} className="mb-0">
              <Col xs={4}></Col>
              <Col xs={8}><h2 className={isMobile ? "text-peach pl-4":"text-peach"}>GWC AT UVA</h2></Col>
            </Row>
    Severity: Major
    Found in src/components/Main/Header/Header.tsx and 1 other location - About 2 hrs to fix
    src/components/Main/Header/Header.tsx on lines 23..26

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

    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 Footer has a Cognitive Complexity of 19 (exceeds 5 allowed). Consider refactoring.
    Open

    function Footer() {
      return (
        <div className="bg-peacock">
          <Row className={`${isMobile ? "footerLogoMobile" : "footerLogoDesktop"} position-absolute`}>
            <img src={whiteLogo} 
    Severity: Minor
    Found in src/components/GirlsHooHack2021/Footer/Footer.tsx - About 2 hrs to fix

    Cognitive Complexity

    Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

    A method's cognitive complexity is based on a few simple rules:

    • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
    • Code is considered more complex for each "break in the linear flow of the code"
    • Code is considered more complex when "flow breaking structures are nested"

    Further reading

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

                        {keynotes.length===0 ? <p>Coming Soon!</p> : 
                          <Row className="justify-content-center mt-5">
                            {keynotes.map((keynote) => 
                                <KeynoteItem key={keynote.id} mem={keynote} />)}
                          </Row>
    Severity: Major
    Found in src/components/GirlsHooHack2023/Speakers/Speakers.tsx and 1 other location - About 2 hrs to fix
    src/components/GirlsHooHack2022/Speakers/Speakers.tsx on lines 82..87

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

    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

                        {keynotes.length===0 ? <p>Coming Soon!</p> : 
                          <Row className="justify-content-center mt-5">
                            {keynotes.map((keynote) => 
                                <KeynoteItem key={keynote.id} mem={keynote} />)}
                          </Row>
    Severity: Major
    Found in src/components/GirlsHooHack2022/Speakers/Speakers.tsx and 1 other location - About 2 hrs to fix
    src/components/GirlsHooHack2023/Speakers/Speakers.tsx on lines 85..90

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

    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 Footer has 61 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    function Footer() {
      return (
        <div className="bg-peacock">
          <Row className={`${isMobile ? "footerLogoMobile" : "footerLogoDesktop"} position-absolute`}>
            <img src={whiteLogo} 
    Severity: Major
    Found in src/components/CareerFair2023/Footer/Footer.tsx - About 2 hrs to fix

      Function Footer has 61 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

      function Footer() {
        return (
          <div className="bg-peacock">
            <Row className={`${isMobile ? "footerLogoMobile" : "footerLogoDesktop"} position-absolute`}>
              <img src={whiteLogo} 
      Severity: Major
      Found in src/components/CareerFair2024/Footer/Footer.tsx - About 2 hrs to fix

        Function JumpStart has a Cognitive Complexity of 18 (exceeds 5 allowed). Consider refactoring.
        Open

        function JumpStart() {
          const [workshops, setWorkshops] = useState([{'id': '', 'workshopName': '', 'workshopDate': '', 'description': '', 'link': '', 'linkName': ''}]);
          const [description, setDescription] = useState({'titleQuestion': '', 'description': ''});
          const [dropdownOpen, setDropdownOpen] = useState(false);
        
        
        Severity: Minor
        Found in src/components/GirlsHooHack2022/JumpStart/JumpStart.tsx - About 2 hrs to fix

        Cognitive Complexity

        Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

        A method's cognitive complexity is based on a few simple rules:

        • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
        • Code is considered more complex for each "break in the linear flow of the code"
        • Code is considered more complex when "flow breaking structures are nested"

        Further reading

        Function Footer has a Cognitive Complexity of 18 (exceeds 5 allowed). Consider refactoring.
        Open

        function Footer() {
          return (
            <div className="bg-peacock">
              <Row className={`${isMobile ? "footerLogoMobile" : "footerLogoDesktop"} position-absolute`}>
                <img src={whiteLogo} 
        Severity: Minor
        Found in src/components/GirlsHooHack2023/Footer/Footer.tsx - About 2 hrs to fix

        Cognitive Complexity

        Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

        A method's cognitive complexity is based on a few simple rules:

        • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
        • Code is considered more complex for each "break in the linear flow of the code"
        • Code is considered more complex when "flow breaking structures are nested"

        Further reading

        Function Footer has a Cognitive Complexity of 18 (exceeds 5 allowed). Consider refactoring.
        Open

        function Footer() {
          return (
            <div className="bg-peacock">
              <Row className={`${isMobile ? "footerLogoMobile" : "footerLogoDesktop"} position-absolute`}>
                <img src={whiteLogo} 
        Severity: Minor
        Found in src/components/GirlsHooHack2022/Footer/Footer.tsx - About 2 hrs to fix

        Cognitive Complexity

        Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

        A method's cognitive complexity is based on a few simple rules:

        • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
        • Code is considered more complex for each "break in the linear flow of the code"
        • Code is considered more complex when "flow breaking structures are nested"

        Further reading

        Function JumpStart has a Cognitive Complexity of 18 (exceeds 5 allowed). Consider refactoring.
        Open

        function JumpStart() {
          const [workshops, setWorkshops] = useState([{'id': '', 'workshopName': '', 'workshopDate': '', 'description': '', 'link': '', 'linkName': ''}]);
          const [description, setDescription] = useState({'titleQuestion': '', 'description': ''});
          const [dropdownOpen, setDropdownOpen] = useState(false);
        
        
        Severity: Minor
        Found in src/components/GirlsHooHack2023/JumpStart/JumpStart.tsx - About 2 hrs to fix

        Cognitive Complexity

        Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.

        A method's cognitive complexity is based on a few simple rules:

        • Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
        • Code is considered more complex for each "break in the linear flow of the code"
        • Code is considered more complex when "flow breaking structures are nested"

        Further reading

        Function Speakers has 60 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

        function Speakers(): JSX.Element {
            const [keynotes, setKeynotes] = useState([{'id': '', 'name': '', 'image': '', 'bio': '', 'headshot': {'url': ''}, 'linkedIn': ''}]);
            // const [panelists, setPanelists] = useState([{'id': '', 'name': '', 'image': '', 'bio': '', 'headshot': {'url': ''}, 'linkedIn': ''}]);
            useEffect(() => {
              const fetchKeynotes = async () => {
        Severity: Major
        Found in src/components/GirlsHooHack2023/Speakers/Speakers.tsx - About 2 hrs to fix
          Severity
          Category
          Status
          Source
          Language