Closed xiaodong2008 closed 2 weeks ago
@xiaodong2008 we are trying to avoid warnings in the docs as much as possible (as they tend to break the reader's flow and are quite distracting). Do you think the benefits of having a warning outweigh the distraction from the warning?
Yes, as per the description in the document, the custom directives part may cause some unexpected results and it is not recommended, so I think adding a warning is better than just adding a conclusion at the end.
The warning should be added at the top part of custom directives
.
@xiaodong2008 would you like me to add the change or would you prefer to create a PR?
I’ll create a PR to make this change, thanks for your suggestion!
In the
Usage on Components
of custom-directives page, there is an unobvious warning: In general, it is not recommended to use custom directives on components.I think we need to change this to a warning block.
Refers to: https://vuejs.org/guide/reusability/custom-directives.html#usage-on-components