PostCSS Sort Alphabetically

PostCSS plugin which sorts css properties alphabetically.
/* Input example */
a{
border: 1px solid black;
color: red;
background-color: red;
}
div{
padding: 10px;
margin: 20px;
color: red;
background-color: red;
}
.class {
flex: 1;
display-flex: 10px;
}
#some {
background-image: url('something');
align-items: center;
}
/* Output example */
a{
background-color: red;
border: 1px solid black;
color: red;
}
div{
background-color: red;
color: red;
margin: 20px;
padding: 10px;
}
.class {
display-flex: 10px;
flex: 1;
}
#some {
align-items: center;
background-image: url('something');
}
Usage
postcss([ require('postcss-sort-alphabetically') ])
See PostCSS docs for examples for your environment.
Contributing
Feel free to open issues, make suggestions or send PRs. This project adheres to the Contributor Covenant code of conduct. By participating, you are expected to uphold this code.