nexus site path corrected
[portal.git] / ecomp-portal-FE / client / bower_components / jqTree / _entries / 24_oncreateli.md
1 ---
2 title: onCreateLi
3 name: options-oncreateli
4 ---
5
6 The function is called for each created node. You can use this to define extra html.
7
8 {% highlight js %}
9 $('#tree1').tree({
10     data: data,
11     onCreateLi: function(node, $li) {
12         // Add 'icon' span before title
13         $li.find('.jqtree-title').before('<span class="icon"></span>');
14     }
15 });
16 {% endhighlight %}