Ext JS 4 introduces a new helper class called
, which allows us to get references to Ext JS Components using CSS/XPath style selector syntax. This new class is very powerful and, as you will find out, is leveraged as an integral part of the MVC architecture system.
In this recipe we will demonstrate how to use the
Ext.ComponentQuery class to get references to specific components within a simple application. We will also move onto exploring how this query engine is integrated into the
Ext.Container class to make finding relative references very easy.
Finally we will look at adding our own custom selector logic to give us fine-grain control over the components that are retrieved.