6

What is the difference between using ext-all.js and ext-all-debug.js?

Does changing to ext-all.js from debug.js improve performance?

Can I assume that switching from debug to normal file will not have any other impacts on the application?

Also, can any one suggest what ext-base.js do?

hop
  • 2,518
  • 11
  • 40
  • 56

4 Answers4

8

Ext-all is basically the minified verion of the debug one. The gain is that it greatly reduces the files size so that clients have to download less. Ext-base are the core functions of ext. If you only use those you could just include that file instead of the huge complete set in ext-all.

On the ext site there used to be a custom js builder where you would pick just the functions you need and it would create a custom js for you with just those modules

Eddy
  • 5,320
  • 24
  • 40
  • This means that ext-base.js is not required when we have already included ext-all.js? – hop Aug 20 '11 at 07:40
  • 1
    No the other way around. ext-base holds all the base functions of ext. ext-all has all the widgets. You need ext-base (25k file) but in a lot of cases you only use a subset of widgets (700k file). – Eddy Aug 20 '11 at 07:52
5

Ext-all-debug is provided so that you can debug through the extjs code. It performs extactly the same operations that ext-all.js does. Using ext-all.js will improve performance since the size of the file is much smaller, hence clients can download and access them faster.

Same is the case with ext-base-debug and ext-base.js. These contain the operations on which ext-all.js depends on, for example Ajax operations. Interchanging these files will not have any effect on your application.

Use the ext-all-debug and ext-base-debug during development. Switch to ext-all.js and ext-base.js when in production.

Varun Achar
  • 14,781
  • 7
  • 57
  • 74
3

THIS INFORMATION HAS CHANGED FOR THOSE USING ExtJS4.1.

After implementing and optimizing an application, I like many, was confused with which process was optimal for 'production implementation'.

This most current documentation for this turned out to be this document on Sencha: http://docs.sencha.com/ext-js/4-1/#!/guide/getting_started

It was difficult to identify, but the key for me was step #3. Deploying Application.

For which these four steps are conducted:

  1. cd to root
  2. sencha create jsb - this creates a manifest of classes used. - it can also be modified prior to build, in case it is needed.
  3. sencha build - creates two files(all-classes.js, app-all.js) - all-classes.js is non min for review. - app-all.js is the production ready file
  4. Setup for prod - these are the remaining includes needed in your production file:
ext-all.css  //minified-css, concatenated and dusted is optimal.
ext/ext.js   //non-debug
app-all.js   //minified, concatenated, app + framework files (only classes used).

Hope this helps someone. : )

Nash Worth
  • 2,524
  • 1
  • 21
  • 28
  • 1
    Interesting !! Is there a way to do extract only the required code with Ext Js 3.4? – hop Feb 20 '13 at 17:00
0

differences between "ext.js" and "ext-debug.js" are:

  1. "ext-debug" is not compressed (or "minified").
  2. "ext-debug" is not run through the Cmd optimizer.

These files otherwise contain exactly the same code. Further, both flavors download required classes from the "src" folder. In short, both of these files are intended to support debugging.

In order to improve the performance,To reduce the downloads to as few files as possible you can use Sencha Cmd. some thing like this
sencha fs minify -yui -from=ext-debug.js -to=ext.js

For Cmd topics ext 4.2.2 doc set is the more current and you can access the dec here

hope this may help you.

Motilal
  • 266
  • 1
  • 9