Some people were asking for some additions to my ExtJS ComboBox replacement, so here is a quick little update.
This version adds in some minor fixes and a new feature. The ComboBox will now properly consume an existing combo. If you do not have selected=”true” on one of the options then this combo will clear the value of the ExtJS Combo box so that no value is selected.
I need to add some more documentation and testing and then I will make it an official UX component. I am also working on some examples of Ext’s combo vs this combo to show you why it is better.
Continue reading ‘ExtJS - Update to ComboBox Replacement’
I consider myself to be an expert in ExtJS. However, there is one component that I have to lookup how to use just about every single time I use it: Ext.form.ComboBox. For me, the default implementation just doesn’t cut it. There are a number of problems I have all the time:
- Forgetting to set “mode” to remote when I provide a store that is obviously “remote”
- Drop-down list width sometimes is smaller than the combo box itself
- I hate having to setup a store every time I need a remote ComboBox
- After the store loads, the value in the input box is not automatically replaced with displayValue
Maybe these issues are more my issues, but I maintain that ComboBox is one of poorer ExtJS components. Here is my replacement:
Please see the new code here: Update to ComboBox Replacement
Use it like this:
var combo1 = new com.succinctllc.form.ComboBox({
displayField:'name',
valueField:'id',
url:"/path/to/dataSource"
}); |
Edited to set lastQuery properly so ComboBox does not load the store twice when autoLoad is set to true (default).