30 Mar 2011 7:33 AM #1
New instructions for using JSBuilder3?
Have the instructions or use changed at all for using JSBuilder3? I am trying to use this with Sencha Touch...and the documentation is still sparse at best, and probably outdated. I see that JSBuilder directory comes with the download package for Touch 1.1, but I see no JSBuilder.jar file anywhere. So how do I launch the tool? I see a batch file...but no docs on using it or how to setup the directory structure properly in a Windows environment.
Love to use these "recommended" tools for performance, just unsure as to why the documentation is always so poor on how to use them. Very frustrating.
30 Mar 2011 12:42 PM #2
So it appears that the JSBuilder has changed a lot since JSB2, not sure as I never used JSB2. But now there appears to be a bat file that you run (for Windows) that you can pair with your own .jsb3 config file to accomplish the concatenation of your various app files into one. That all works fine, or so it appears to.
However, I am not really seeing any compression whatsoever, do we have to do something different to force the JSB3 process to compress? I simple made a call the JSBuilder.bat file with the source and destination dirs specified.
I also tried to run the ycompressor on my own, and it reported illegal characters and syntax errors on every whitespace line and comment symbols. Speaking of, why wouldn't these be stripped out of a minimized file?
Would really like Sencha, or someone who knows JSB3 to jump in here and enlighten me, or point me at some JSB3 specific instructions.
3 Jun 2011 2:43 AM #3
I tried to use JS Builder 3, included in Sencha Touch 1.1.0. While it does combine source files, it doesn't minify them. So I explicitly called ycompressor. Then you will get the illegal character errors. It seems that JSBuild encodes the resulting file in utf-8. You can get illegal character errors by specifying --charset utf-8 option for ycompressor.
So to combine and minify your js source files, create a build.bat file like this:
call \path\to\jsbuilder\jsbuilder.bat -p yourapp.jsb3 -d deploy java -jar \path\to\jsbuilder\ycompressor\ycompressor.jar deploy\all.js -o deploy\all-min.js -v --charset utf-8
3 Apr 2012 1:21 PM #4
I know it's way late, but in case someone else comes around with the same question... there's a "compress" boolean option you can specify at the package level in your jsb3 file. There's a sample here that shows it, just below the "The .JSB3" header.
Last edited by unmicd; 3 Apr 2012 at 1:25 PM. Reason: Example contained use of deprecated code.
By elishnevsky in forum Sencha Touch 1.x: DiscussionReplies: 2Last Post: 29 Nov 2011, 8:04 AM
By ssdesign in forum Sencha Touch 1.x: DiscussionReplies: 3Last Post: 8 Aug 2010, 8:05 PM
By GregT in forum Ext.DirectReplies: 4Last Post: 8 Oct 2009, 8:10 AM
By .:lay-z-cow:. in forum Ext 2.x: Help & DiscussionReplies: 2Last Post: 21 Apr 2008, 2:24 AM
By yaip in forum Ext 2.x: Help & DiscussionReplies: 3Last Post: 20 Nov 2007, 1:40 PM