If you are like me and have been following the recipes in this chapter (and probably the entire book) in sequence, you will have noticed that, in the previous recipes, we were loading the
TreeStore instance bound to the
TreePanel instance with a huge dataset, all at once. This is not always practical and may not be what you want. You may want to only load the nodes within a given parent first, and then load children of those nodes from the server on demand — usually when the node is clicked.
It turns out that building this sort of asynchrony into
TreePanel is so trivial that we don't have to do anything special besides:
TreeStoreinstance from a
TreeLoaderinstance that fetches the actual data using ...