Skip to content
  • Unlock Pro
  • Log in with GitHub
Solution
Submitted over 3 years ago

Easybank landing page using React, SCSS and mobile-first workflow

Neil Khatri•620
@nkhatri7
A solution to the Digital bank landing page challenge
View live sitePreview (opens in new tab)View codeCode (opens in new tab)

Solution retrospective


My first time using SCSS and functional components in React, how did I go? Please be as harsh as you can.

Code
Select a file

Please log in to post a comment

Log in with GitHub

Community feedback

  • Alex•2,010
    @AlexKMarshall
    Posted over 3 years ago

    This looks good at a lot of screensizes. But careful, you have some significant horizontal overflow on between about 800px and 1200px screen width. Also, on very large monitors, everything is a bit too wide for my tastes, I'd wrap the main content in a max-width container maybe capping it at about 1200px

    The mobile menu doesn't appear to do anything.

    Careful with your HTML. Your list of navigation elements should be

    <nav>
      <ul>
         <li><a href="/">Home</a></li>
         <li><a href="/">About</a></li>
      </ul>
    </nav>
    

    Also you have multiple h1 elements, we only want one on the page. And all other headings should flow in order. You need a <main> wrapping everything that's not the header and the footer. And <section className="footer"> should just be <footer>

    For the React code. I see you have a useEffect which is setting up a listener to the resize event in order to apply different classes to some elements. Just use a media query to do that. We don't need javascript there. It's really poor for performance. If you do need the size of the window in the javascript for some reason (For some far more complicated use-case), then use the resize-observer api as it is far more performant. But if something can just be done with CSS, do it with CSS.

    Other than that, there's no specific issues with the React code. Except that it doesn't really make that much sense to use React for something like this. It's fine to use this as practice with setting up React, but as it's a static website, with as far as I can tell no real javascript requirements, making the user download the full react bundle to run the site, is fairly poor UX.

    The benefits of a framework like React or Vue come from either when you have heavy interactivity. Or when you have a lot of re-usable components. And there are neither of those here.

    If you want to really practice React skills, then I would try some of the app challenges instead like the Tip Calculator or the Clock. Just make sure you've got a decent handle on semantic HTML as well.

    Marked as helpful
  • Nick•760
    @Nick331102
    Posted over 3 years ago

    how do you add a dark overlay to the body when the hamburger menu is clicked?

Join our Discord community

Join thousands of Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!

Join our Discord
Frontend Mentor logo

Stay up to datewith new challenges, featured solutions, selected articles, and our latest news

Frontend Mentor

  • Unlock Pro
  • Contact us
  • FAQs
  • Become a partner

Explore

  • Learning paths
  • Challenges
  • Solutions
  • Articles

Community

  • Discord
  • Guidelines

For companies

  • Hire developers
  • Train developers
© Frontend Mentor 2019 - 2025
  • Terms
  • Cookie Policy
  • Privacy Policy
  • License

Oops! 😬

You need to be logged in before you can do that.

Log in with GitHub

Oops! 😬

You need to be logged in before you can do that.

Log in with GitHub

How does the accessibility report work?

When a solution is submitted, we use axe-core to run an automated audit of your code.

This picks out common accessibility issues like not using semantic HTML and not having proper heading hierarchies, among others.

This automated audit is fairly surface level, so we encourage to you review the project and code in more detail with accessibility best practices in mind.

How does the CSS report work?

When a solution is submitted, we use stylelint to run an automated check on the CSS code.

We've added some of our own linting rules based on recommended best practices. These rules are prefixed with frontend-mentor/ which you'll see at the top of each issue in the report.

The report will audit all CSS, SCSS and Less files in your repository.

How does the HTML validation report work?

When a solution is submitted, we use html-validate to run an automated check on the HTML code.

The report picks out common HTML issues such as not using headings within section elements and incorrect nesting of elements, among others.

Note that the report can pick up “invalid” attributes, which some frameworks automatically add to the HTML. These attributes are crucial for how the frameworks function, although they’re technically not valid HTML. As such, some projects can show up with many HTML validation errors, which are benign and are a necessary part of the framework.

How does the JavaScript validation report work?

When a solution is submitted, we use eslint to run an automated check on the JavaScript code.

The report picks out common JavaScript issues such as not using semicolons and using var instead of let or const, among others.

The report will audit all JS and JSX files in your repository. We currently do not support Typescript or other frontend frameworks.

Frontend Mentor for Teams

Frontend Mentor for Teams helps companies and schools onboard and train developers through project-based learning. Our industry-standard projects give developers hands-on experience tackling real coding problems, helping them master their craft.

If you work in a company or are a student in a coding school, feel free to share Frontend Mentor for Teams with your manager or instructor, as they may use it to help with your coding education.

Learn more

Oops! 😬

You need to be logged in before you can do that.

Log in with GitHub

Oops! 😬

You need to be logged in before you can do that.

Log in with GitHub