Reputation: 446
Assuming I have a situation when we want to enchant some of our html with a nice reusable css style I have two options:
I can write a css class that is available globally and add the class to the element or
I can write a directive which will encapsulate the css, however that directive will do nothing more than add css to the HTML tag
In which situations should I use the first solution and in which the second?
Upvotes: 0
Views: 42
Reputation: 657476
If CSS can do what you want, I would stick with CSS. If you need more flexibility that is hard to achieve with CSS alone I would try to make it work using a directive.
Upvotes: 1