Created
December 10, 2013 18:51
-
-
Save jbutko/7895980 to your computer and use it in GitHub Desktop.
SCSS, SASS, CSS: Margin mixin
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Mixin for consistent top/bottom margin, default 64px | |
Usage: | |
@include margin(top, 2); | |
Result: margin-top: 32px; | |
(C) Jozef Butko | |
*/ | |
@mixin margin-base($position: bottom, $divider: 1) { | |
margin-#{$position}: (64px/$divider); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment