Design comparison
SolutionDesign
Solution retrospective
** Built with**
- Semantic HTML5 markup
- CSS custom properties
- Flexbox
- Mobile-first workflow
** What I learned**
- Custom properties aren't usable on media queries.
/* I've tried this but it turns out that it's not possible. */ @media screen and (min-width: calc(var(--desktop) / 2)){ }
- Right use of pseudo-elements.
.card.sedans .card-details::before {
content: url(images/icon-sedans.svg);
}
- Usage of @import rule in css file instead of link tag in html file
@import url('https://fonts.googleapis.com/css2?family=Big+Shoulders+Display:wght@700&display=swap');
- Importance of comments. I saved some time by not looking back and fort anymore between the style guide and my css file.
I would greatly appreciate it if you kindly give me some feedback. Happy coding!
Community feedback
Please log in to post a comment
Log in with GitHubJoin 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