Created
March 24, 2016 02:21
-
-
Save alexcarpenter/32e9f4c1328e63bbe3dd to your computer and use it in GitHub Desktop.
Sass depreciation warning
This file contains 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
// warning message is optional | |
@mixin deprecated($item, $msg: null) { | |
@if $msg { @warn "DEPRECATION WARNING: #{$item} -- #{$msg}"} | |
@else { @warn "DEPRECATION WARNING: #{$item}" } | |
} | |
.button--login { | |
@include deprecated(&, 'use "btn" prefix'); | |
color: blue; | |
} | |
.button--ex2 { | |
@include deprecated(&); | |
} | |
.btn--login { | |
color: lightblue; | |
} | |
from: http://codepen.io/una/pen/EKZKgm?editors=0101 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment