Finds sidebar nodes that have attributes defined inattr and returns them or an empty array.
find([parent], attrs)

parent | string, id of the parent node (optional)
attrs | object, attributes to match

Returns array.

#### Description

The attrs argument needs to be specified. It can be an empty object - {} - which will return you an array of all nodes.
You can optionally specify parent, which is an id of the parent node. If parent is specified then it will limit the search scope to that parent and its subnodes.
If you defined the object in the following way: $('#sidebar').w2sidebar({ name : 'sidebar', nodes: [ { id: 'id-1', text: 'Level 1', disabled: true }, { id: 'id-2', text: 'Level 2' }, { id: 'id-3', text: 'Level 3' } ] }); To get all disabled nodes: var nodes = w2ui['sidebar'].find({ disabled: true }); console.log(nodes); To get all nodes: var all = w2ui['sidebar'].find({}); console.log(all);