0

I want to include only required components from Extjs library.

I have seen couple of articles as follows,

http://blog.mdsohelrana.com/2012/10/21/how-to-compile-extjs-for-production-to-include-only-the-needed-ui-elements/#comment-461257

Ext deployed application: ext.js vs ext-all.js - what's a better option?

Above articles says that after editing index.html file with required components and using following commands,

sencha create jsb -a index.html -p site.jsb3

sencha build -p site.jsb3 -d

will generate app-all.js file. But app-all.js file loading all components from extjs library..

Is there any alternate solution?

Community
  • 1
  • 1
Sparrow
  • 355
  • 4
  • 19

1 Answers1

0

The first article you mentioned is really old (2012). This command is no longer supported. I recommend to read the Sencha Cmd docs link . You should also mentioned what version of Ext JS and Cmd you using. I would say that you need use this command

sencha app build production

Then navigate to build/production. In ext folder, you will always have all ExtJS library.

Alexander_Dracka
  • 123
  • 2
  • 15
  • Using Extjs 6.x version and sencha cmd 6.0.2 – Sparrow Oct 16 '15 at 08:34
  • Ok and what is the problem then? When you make a production command you create a folder (build/production) where is your build output which contains only required Ext JS libraries. – Alexander_Dracka Oct 16 '15 at 09:10
  • index.html - in this file i have added , Ext.require([ 'Ext.grid.*' ]); then created JSB and single JS file using sencha commands. So now in my application, I should be able get only grid component from ext library, right? But it is loading everything. – Sparrow Oct 16 '15 at 09:24