Looks like we can't reproduce the issue or there's a problem in the test case provided.
-
Sencha Premium Member
[5.0.1] User extension childEls are null
Hello !
I want to extend Ext.form.field.Text to add an example text below the input.
Here is the code :
Code:
Ext.define('Ext.ux.form.field.Example', {
extend: 'Ext.form.field.Text',
childEls: ['exampleEl'],
afterSubTpl: ['<span id="{id}-exampleEl">This is an example !</span>'],
afterRender: function() {
var me = this;
me.callParent(arguments);
console.log(me.exampleEl);
}});
I want then access to the exampleEl but it is always null 
Any idea why ?
Thanks !
EDIT : You can reproduce the problem is this fiddle
Last edited by archimed-isv; 17 Oct 2014 at 6:03 AM.
Reason: Fiddle added
-
Hi,
In Ext 5.x you'll use the "data-ref" attribute to marry elements to childEl references, which is a change from 4.x.
See the example here:
-
Sencha Premium Member
This information is not in any of the documentation, which still points to broken examples of how childEls are supposed to work (unless I missed it? but I'm looking at the 5.1 api docs). I don't see it in the upgrade guide either.
I think that still counts as a bug (of the documentation), no?