Use a directive to augment a DOM
node:
- To transform its contents in a regular manner.
- To add a behaviour that is general and reusable.
Do not use a directive:
- To augment or manipulate shared
scope
(use acontroller
instead). - To allow a partial to include another partial specific to your application (this is not composable, use nested states instead).