Submitted about 2 months agoA solution to the Loopstudios landing page challenge
Loopstudios with BEM and Sass
bem, sass/scss
P
@Joshk7

Solution retrospective
What are you most proud of, and what would you do differently next time?
I liked my use of a sass function that converts pixels to a rem ratio:
What challenges did you encounter, and how did you overcome them?@use "sass:math"; @function rem($pixel) { @if math.is-unitless($pixel) { @return math.div($pixel, 16) + rem; } @else { @error 'Don\'t use units when using the rem function. Only numbers.'; } } @function em($pixel) { @if math.is-unitless($pixel) { @return math.div($pixel, 16) + em; } @else { @error 'Don\'t use units when using the em function. Only numbers.'; } }
One challenge I encountered was how to layout the file structure for all of my scss files. I looked into the 7-1 architectures and settled on a hybrid of that.
What specific areas of your project would you like help with?I'd like any tips on how to setup and structure sass projects.
Code
Loading...
Please log in to post a comment
Log in with GitHubCommunity feedback
No feedback yet. Be the first to give feedback on Josh Kahlbaugh's solution.
Join 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