View Full Version : Is this a bug ? not classes from bootstrap.js get copy to all-classes.js

18 Oct 2012, 3:43 PM
Not a duplicate post, want to make sure this is not a bug. looks like not all classes from bootstap.js goes to all-classes.js file. for example
I created the default app with sencha cmd and ran the build, the bootstrap has following classes

"Ext.form.Label": "ext/src/form/Label.js",
"Ext.form.Labelable": "ext/src/form/Labelable.js"

but generated /all-classes.js has only Labelable.js , it is missing the Label.js and that is why my app is giving me the following error.

Uncaught Error: [Ext.createByAlias] Cannot create an instance of unrecognized alias: widget.label

21 Oct 2012, 3:36 AM
To have those classes in production build you have to use 'requires' or 'use'. Bootstrap seems to be needed for Loader at developing.

24 Oct 2012, 11:41 PM
@vadimv - Thanks. That is essentially correct.

@hsingh11 - You would have to post more details to be certain, but the idea of the bootstrap is to operate in non-build mode only. The compiler looks at a block in the markup file like this:

<!-- <x-compile> -->
<!-- <x-bootstrap> -->
<script src="ext/ext-dev.js" type="text/javascript"></script>
<!-- </x-bootstrap> -->

<script src="js/app.js" type="text/javascript"></script>
<!-- </x-compile> -->

The idea being that the x-compile area is replaced by the script tag for all-classes.js but the bootstrap area is ignored when producing it.

I hope that clarifies things, but it you are still having an issue please provide a complete code example.