4 ms·
> You haven't changed the problem, or the amount of work, you are just using a different layer to implement it. Changing the layer you're implementing on is th
by aphextron 8y ago
> You haven't changed the problem, or the amount of work, you are just using a different layer to implement it.
Changing the layer you're implementing on is the whole point. It's about maintainability and keeping things encapsulated.
Now when someone comes back to look at this button a year later, they're not left wondering why this usage of "Button" is colored blue, and tracking down the utility class. They will know that it's an instance of "BlueButton" and can just edit the component directly.
- wvenable 8y agoHow is a component called BlueButton more informative than <button class="blue">? The information content is exactly the same. Now, more than likely the component isn't called BlueButton and the CSS class isn't called "blue" but rather both would have a name more semantically appropriate.