# Example 1 - load json data

In this example we load the data using the data option. As you can see, the data is an array of objects.

- The label property defines the label of the node.
- The children property is an array of nodes.

### html

###

    <div id="tree1"></div>

### javascript

    var data = [
        {
            label: 'node1',
            children: [
                { label: 'child1' },
                { label: 'child2' }
            ]
        },
        {
            label: 'node2',
            children: [
                { label: 'child3' }
            ]
        }
    ];

    $('#tree1').tree({
        data: data
    });