View Full Version : Do we have any tool to bundle all the java script?

14 Feb 2012, 10:30 AM
Hello, i was trying to us the SDk tools to minify the java script but it is only minifying the app.js file and i have to use ext-all.js file as a minified version, but not any other java script files i have, does sencha provide any tool to bundle all the java script files?

please let me know if you have anything like that or am i doing something wrong....for now i am following



Loading the Project Name Project
Loaded 0 Packages
Loaded 2 Builds
* Parse all-classes.js with options:
- debug: true
- debugLevel: 1
* Parse app-all.js with options:
- debug: false
- debugLevel: 1
* Compress and obfuscate app-all.js...
Copy resources...
Done building!

14 Feb 2012, 10:54 AM
In your application files, are you using things like requires or views to specify what files those classes require?

14 Feb 2012, 11:08 AM
yes. we do have requires for telling the dependency and controllers but not views.

14 Feb 2012, 11:20 AM
When you do the build are you using the ext-debug.js file? The SDK Tools go through all the require properties (requires, uses, controllers, etc) and builds the dependency list.

14 Feb 2012, 11:33 AM
No i am using this code in my index.html file

<link rel="stylesheet" type="text/css" href="resources/css/ia-mgr.css" />
<link rel="icon" type="image/x-icon" href="resources/images/favicon.ico" />
<!--[if IE 9]>
<link rel="stylesheet" type="text/css" href="resources/css/IE9.css" />
<script type='text/javascript' src='ext/ext-all-debug.js'></script>
<script type='text/javascript' src='app.js'></script>

14 Feb 2012, 11:43 AM
To do the build you shouldn't use one of the all scripts

14 Feb 2012, 11:52 AM
So you mean to say instead of ext-debug-all.js i should use ext.js file and it will minify all my java script files?

14 Feb 2012, 11:57 AM
That will help get the Ext JS classes to be bundled into the mix. I'm not too sure why your application classes aren't getting picked up at least.