1.0.6 • Published 7 years ago
greens v1.0.6
Greens
Sample usage
var css = require('greens')(),
bodyRule = css.add('body',{
backgroundColor: 'black',
fontSize: 'big'
}),
rotation = css.add('@keyframes rotation',{
from: {
transform: 'rotate(0deg)'
},
to: {
transform: 'rotate(360deg)'
}
}),
rot50;
bodyRule.fontSize = 'small'; // Dynamically change the rules
css.remove(bodyRule); // Remove rule
rot50 = rotation.add('50%',{
transform: 'rotate(90deg)' // Dynamically add a rule to an @rule
});
rotation.remove(rot50); // Remove the rule