postcss-pxtorem
postcss-pxtorem copied to clipboard
Avoid needing to declare each side of the box model
Great plugin, very useful.
However with properties like margin, padding etc it would be great to use just margin and it cover off margin-top, margin-bottom etc without declaring them all. It gets quite verbose when you add padding in there too.
That's a good point. Thanks for the idea. I think that can be done.
It might be a little while before I get to this. For now, maybe hide the white list in a separate file.
// postcss-pxtorem white list
module.exports = [
'font',
'font-size',
'line-height',
'letter-spacing',
'margin',
'margin-top',
'margin-right',
'margin-bottom',
'margin-left',
'padding',
'padding-top',
'padding-right',
'padding-bottom',
'padding-left'
];
Sure, it's not a big problem. Just a nice to have