When comparing CSSTidy vs cssnano, the Slant community recommends cssnano for most people. In the question“What are the best CSS minifiers?” cssnano is ranked 5th while CSSTidy is ranked 7th. The most important reason people chose cssnano is:
Trims whitespace inside and around rules, selectors & declarations, plus removes the final semicolon inside every selector.
Ranked in these QuestionsQuestion Ranking
Pros
Pro Full CSS2 support
Pro Aivailable as an executable and PHP script
Pro Excellent compression
On average produces a file that's 63.29% of the original size minified and 19.44% gzipped.
Pro Whitespace & final semicolon removal
Trims whitespace inside and around rules, selectors & declarations, plus removes the final semicolon inside every selector.
Pro Comment removal
postcss-discard-comments removes comments in and around rules, selectors & declarations. Note that any special comments marked with ! are kept by default.
Pro Calc Function
Pro Duplicate rules removed
Pro Focused optimisations
Pro Autoprefixer
Add needed prefixes and remove unnecessary based on its browsers option and can I use data