Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor columns.sass to use map values #2559

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Refactor columns.sass to use map values #2559

wants to merge 2 commits into from

Conversation

james-wasson
Copy link
Contributor

@james-wasson james-wasson commented Jul 13, 2019

This is an improvement.

This is an improvement in readability to the columns.sass.

There are too many blocks of code repeating .is-one-third-* over and over.

Proposed solution

We are using a name-value map to reference very well defined variable-name values and looping through them rather than specifying each one directly.

Note: Decreased the file size by more than half (~300 lines)

Tradeoffs

This solution may increase build time - but not substantially.

Testing Done

These changes do not affect the output CSS file

I did look at the documentation site to ensure all changes are working correctly

Changelog updated?

Yes.

- This improves readability
- This does not hinder the individual components
- These changes do not affect the output css
@james-wasson james-wasson changed the title Refactoring columns.sass to use map values Refactor columns.sass to use map values Jul 25, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant