docs(guide/component): clarify when to use directives instead of components

Clarify that components cannot be used to perform actions in compile
and prelink functions.

Closes #15042
PR (#15100)
This commit is contained in:
Austin O'Neil
2016-09-08 07:21:10 -06:00
committed by Martin Staffa
parent 8ec3f4b518
commit c729554281
+1 -2
View File
@@ -19,8 +19,7 @@ Advantages of Components:
When not to use Components:
- for directives that rely on DOM manipulation, adding event listeners etc, because the compile
and link functions are unavailable
- for directives that need to perform actions in compile and pre-link functions, because they aren't available
- when you need advanced directive definition options like priority, terminal, multi-element
- when you want a directive that is triggered by an attribute or CSS class, rather than an element