DEV Community

Discussion on: I Created 500+ Dev questions and Launched a Quiz platform 🏆🎉

Collapse
 
afif profile image
Temani Afif

There are a few issues with the CSS quizz

1) The question about border is not valid because the order is not important. If you check the formal syntax (developer.mozilla.org/en-US/docs/W...) you will notice the use of || which mean any order so solid grey 1px is also valid (like grey solid 1px, grey 1px solid, etc). You should also remove the quotes '
2) The question about position:fixed is not very accurate because the element will not always say fixed on scroll. There are some particular cases where this will break. So technically the answer can be false (related: stackoverflow.com/q/52937708/8620333)
3) The question about !important is not very clear. Not sure what you meant by "user-defined" but !important simply increase the specificity and will not necessarily take precedence because we also need to check the selectors (we may have another rule with !important)
4) The overflow question is also not accurate because we aren't obliged to set height (or width). There are a lot of cases where other properties enter in play. Example: jsfiddle.net/e2atgo8d/ (we don't have height and no block elements)
5) for the one about z-index, we cannot say that only z-index control the layers. A lot of other properties enter in play and we can control the layers without using z-index. I can do it with only transform. So z-index is one property among many that can have an impact on the painting order.

Collapse
 
madza profile image
Madza • Edited

Thanks for the valuable input! 👍❤
I will review the questions and edit them accordingly 😉