Improve Compatibility with Browser Fallbacks- What am I missing

Improve Compatibility with Browser Fallbacks- What am I missing
0

#1

Tell us what’s happening:
Hello all,

The challenge here wants me to implement a fallback to the variable background image with a regular solid red color. I thought I had accomplished this but the site will not let me pass the challenge. Wondering if anyone could shed some light onto this

Your code so far


<style>
  :root {
    --red-color: red;
  }
  .red-box {
    background-color: red;
    background: var(--red-color);
    height: 200px;
    width:200px;
  }
</style>
<div class="red-box"></div>

Your browser information:

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

Link to the challenge:
https://learn.freecodecamp.org/responsive-web-design/basic-css/improve-compatibility-with-browser-fallbacks/


#2

You have to give “red” color value to background and not background-color property.
Hope this helps.


#3

just remove background-color:red;
and add
background:red;