Skip to content
  • Unlock Pro
  • Log in with GitHub
Solution
Submitted about 5 years ago

HTML and CSS site using Flexbox

Mindaugas Jocevicius•70
@MindaugasJ88
A solution to the Single price grid component challenge
View live sitePreview (opens in new tab)View codeCode (opens in new tab)

Solution retrospective


Hi, I just finished my first HTML and CSS project, therefore I have some questions:

  1. Does my website meets the responsive website standards? As I was trying to reduce the size of screen, the columns wraps and turns into the mobile version. Do you see any places where it's working/looking wrong?
  2. When it's best to use percent values and when fixed pixels values? At first I thought that I need to use everywhere percent values in order to make everything responsive, but I saw that it's difficult when you using percentage both to parent and child items. So I used both pixels and percentage, just wondering what is the best practice?
  3. Can you check the classes code? Now I had literraly styled everything in styles.css files. First I had styled tag selectors and then created bunch of class selectors classes. What could be improved in terms of styling logic and naming? Was my approach effective?

I'm grateful for any feeback. Thank you! ps: code is in two files - index.html and css/styles.css

Code
Select a file

Please log in to post a comment

Log in with GitHub

Community feedback

  • Alexander Heo•80
    @AlexanderHeo
    Posted about 5 years ago

    Here's my two cents on fixed vs responsive sizing. Keep in mind I am new to webdev, about 8 months of studying and i just starting to look for my first job.

    So this has been my latest approach: the main container - responsive. this way the background image or color gradient will resize automatically with the screen. images, buttons, and other components - fixed. i don't want a button to stretch with the screen. same for images, i always set a specific pixel by pixel width and height on images, or image containers, and use media queries to make them responsive. certain things like side bars i like to set a fixed width, while the rest of the DOM will be set responsive. As far as selectors: this was something that took me a long time to get, and i'm still modifying my system with every project. but bottom line is to have a system. i like to plan out the styling so i know which elements will need styling, and which classes can be reused. learn the sibling and child selectors, and pseudo-classes like :nth-child(), :first-of-type, as these will help you select specific elements without giving every single element a class name. Hope this helps; these are such dense topics and there are so many different approaches to them.

  • Moustafa Mahmoud•245
    @DevMoustafa97
    Posted about 5 years ago

    good work but if you don't mind your solution as small issues

    • price $29 should be bold using css or just b tag
    • you should resize your signup button and take care of padding and font size inside it

    but still great work

  • Mindaugas Jocevicius•70
    @MindaugasJ88
    Posted about 5 years ago

    Thank you for the answers!

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

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.

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

Oops! 😬

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

Log in with GitHub