How to customize ICONS for the El-Tree component
If you want to use the element UI tree component and you don’t want the tree icon to come with it, you need to customize the icon
1. Remove the icon attached to tre
The Tree component has an icon of its own, as shown below
We useicon-class
Property to remove the icon
2. Customize the icon styles
Here, I used the SVG-icon component to customize the icon, to determine whether the current icon has child, and then determine whether it has child state, and then to set its icon
In the tree component, you can judge the status of nodes by receiving node attributes, which store information about various nodes