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

Profile Card

Paulina•20
@paulinahs
A solution to the Profile card component challenge
View live sitePreview (opens in new tab)View codeCode (opens in new tab)

Solution retrospective


Constructive feedback please :)

I am aware I put the text at the bottom of the page, which might not have been needed.

Code
Select a file

Please log in to post a comment

Log in with GitHub

Community feedback

  • Daniel•280
    @Dani237
    Posted over 3 years ago

    Hi Paulina, first of all, great job.

    Some considerations about your report.

    For the HTML Validations:

    • Make sure that you are declaring the styles in your css file. So don't write styles code in your html file. In your specific case, '100%' is not an allowed value for 'width'.

    For the Accessibility:

    • Make sure that you are using a main tag in all your html projects. That is for the main content of your site and is very important for the browser.
    • You can put your main tag arround this piece of code.
    <main>
    <div class="card">
      <img class="background-user" alt="user background pattern" src="images/bg-pattern-card.svg" width="100%">
      <div class="profile">
      <img class="imgpf" src="images/image-victor.jpg" alt="profilepic" width="100" height="100">
      <h1 class="name">Victor Crest <span class="age">26</span></h1>
     <p class="london">London</p>
      </div>
    <div class="smallerinfo">
      <ul>
          <li>
              <span>80K</span>
              <span>Followers</span>
          </li>
          <li>
              <span>803K</span>
              <span>Likes</span>
          </li>
          <li>
              <span>1.4K</span>
              <span>Photos</span>
          </li>
      </ul>
    </div>
    </div>
    </main>
    
    • You can do the same with the footer tag
    <footer>
     <div class="attribution">
        Challenge by <a href="https://www.frontendmentor.io?ref=challenge" target="_blank">Frontend Mentor</a>.
        <br>
        Coded by <a href="https://github.com/paulinahs" target="_blank">Paulina Hesselius</a>.
      </div>
    </footer>
    

    I hope this can be helpful to you! :D

    Marked as helpful
  • Sebastian•1,580
    @dnksebastian
    Posted over 3 years ago

    Hi Paulina,

    overall you did well! There's only a couple of small things which you might want to tweak up:

    • it's generally a good practice to name your classes or ID's in a way that explains what the given element does; for example you could use 'user-location' here: <p class="london">,
    • you could easily get rid of the accessibility issues by using semantic elements, such as <section> or <footer> instead of plain <div>'s,
    • it's recommended to avoid using HTML when it comes to the visual aspect of your site - that's why if you want to keep the line break in your footer, you can use CSS or just wrap your sentences in a block element, instead of using the <br> tag. Anyway, these are really minor points :)

    Hope that helps, keep it up!

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