Store Data with Sass Variables

Store Data with Sass Variables
0.0 0

#1

Tell us what’s happening:

I cant find a solution for this code, if anyone cal help it would be awesome! Its the first lesson for Sass:
This is the quote for the exercise.
“Create a variable $text-color and set it to red. Then change the value of the color property for the .blog-post and h2 to the $text-color variable.”

Your code so far


<style type='text/sass'>
  
  $text-color: red;
  
  .header{
    text-align: center;
  }
  .blog-post, h2 {
    color: $text-color;
  }
</style>

<h1 class="header">Learn Sass</h1>
<div class="blog-post">
  <h2 color="red">Some random title</h2>
  <p>This is a paragraph with some random text in it</p>
</div>
<div class="blog-post">
  <h2 color="red">Header #2</h2>
  <p>Here is some more random text.</p>
</div>
<div class="blog-post">
  <h2 color="red">Here is another header</h2>
  <p>Even more random text within a paragraph</p>
</div>

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/66.0.3359.181 Safari/537.36.

Link to the challenge:
https://learn.freecodecamp.org/front-end-libraries/sass/store-data-with-sass-variables


#2

This is the original code.

.header{ text-align: center; } .blog-post, h2 { color: red; }

Learn Sass

Some random title

This is a paragraph with some random text in it

Header #2

Here is some more random text.

Here is another header

Even more random text within a paragraph


#3

If you find a bug you can report to GitHub - FCC issues


#4

Your code is correct, this lesson appears to be bugged.


#5

Or was, it worked for me a few minutes ago.


#6

It’s not working for me either.