freeCodeCamp: Correct solution fails without correct boilerplate HTML - Nest an Anchor Challenge

Challenge Nest an Anchor Element within a Paragraph has an issue. User Agent is: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/57.0.2987.133 Safari/537.36. Please describe how to reproduce this issue, and include links to screenshots if possible.

My code:


<link href="https://fonts.googleapis.com/css?family=Lobster" rel="stylesheet" type="text/css">
<style>
  .red-text {
    color: red;
  }

  h2 {
    font-family: Lobster, Monospace;
  }

  p {
    font-size: 16px;
    font-family: Monospace;
  }

  .thick-green-border {
    border-color: green;
    border-width: 10px;
    border-style: solid;
    border-radius: 50%;
  }

  .smaller-image {
    width: 100px;
  }
</style>

<h2 class="red-text">CatPhotoApp</h2>

<p>View More <a href= "http://www.freecatphotoapp.com"> cat photos</a></p>

<img class="smaller-image thick-green-border" src="https://bit.ly/fcc-relaxing-cat" alt="A cute orange cat lying on its back.">


About this issue

  • Original URL
  • State: closed
  • Created 7 years ago
  • Comments: 15 (7 by maintainers)

Commits related to this issue

Most upvoted comments

hi @no-stack-dub-sack, first-timer here! If its okay with you i’d like to take on this issue 😃 šŸ’Æ

@infinityl00p Great! Let me check it out

@danjumaharjan it looks like @LukeGeneva is correct, the test cases are expecting the 2 <p> tags that you removed to still be there. Other than that your code is right.

@freeCodeCamp/moderators this is interesting. Anyone want to weigh in on this? I think either we should modify the tests so that they pass even if other non-required elements are deleted, or have an an additional test case that says no other code should be modified.

The initial code has two <p> elements pre-filled. The test cases are expecting these to still be present, but they appear to be missing from your solution code.

<p class="red-text">Kitty ipsum dolor sit amet, shed everywhere shed everywhere stretching attack your ankles chase the red dot, hairball run catnip eat the grass sniff.</p>
<p class="red-text">Purr jump eat the grass rip the couch scratched sunbathe, shed everywhere rip the couch sleep in the sink fluffy fur catnip scratched.</p>