Hacker News new | ask | show | jobs
by baash05 1547 days ago
My rails app has really nice HTML and CSS. All the class names are logical and lovely to code in.

My rails app takes that lovely HTML and CSS, and (in the middleware) it makes it look really ugly. It removes all the sugar, white space, newlines and SCSS niceness. It replaces all the lovely class names with numbered class (c1, c2...). It removes unused classes from the CSS.

So... it's well programmed, and very ugly when viewed by the user. It's smaller and semantically correct, but reading it client side is not really possible for a human, or a scraper (because the class names change)

Now the ugly HTML/CSS is displayed rather nicely, so the end results are (to the user) nice.