20 Apr 2010 12:07 AM #1
I have doubt in my mind....
Will Minify JS impacts Client Performance ? Maybe with better or worst performance..
Of couse it is better for load perfomance... the file is smaller.. so less time to download it..
But I have some question about JS engine.. will it be impacted ?
I found a slide talking about it.. and seems that in same case it will impact client performance...
I haven't idea using extjs minify files....
I'm trying to profile my application.. it is very slow..
What kind of profiler do you suggest ?
I'm trying standard firefox and chrome progfiler and also the dynaTrace AJAX Edition (but it is based on IE and my application doesn't support it...)
a best practise guide for performance will be very appreciate
FYI. my application is a full J2EE ERP application based (about >950 EJB Entity Bean 2.1 , > 1200 EJB Session Bean, > 900 KB of JS code not minimized ......)
tywe make IT work for you
20 Apr 2010 12:11 AM #2
- Join Date
- Apr 2007
- Sydney, Australia
- Vote Rating
Simply minifying won't have any impact on the client. Essentially all it's doing is removing comments, whitespace and renaming variables to something smaller where it's appropriate.Evan Trimboli
Twitter - @evantrimboli
Don't be afraid of the source code!
20 Apr 2010 12:36 AM #3
exactly, JS engine will behave the same.
When app is slow it's mostly because of large requests or bad app design. I use Firebug to profile parts of code
simple counter in functions: console.count('Title');
profile: console.profile('title') and console.profileEnd()
simple timer: console.time('name') and console.timeEnd('name');
20 Apr 2010 3:42 AM #4
20 Apr 2010 2:21 PM #5
As Jay said it will in some cases, depending on the level of compression speed up the client js processing. In addition to not parsing extra whitespace and comments, some compressors will drastically shorten var names to single chars, further reducing the memory footprint of the physical js in the browser
20 Apr 2010 10:36 PM #6
are minify js distributed by ExtJS created with a "good" compression engine ?
Of course I'm using FF profiler to check performance issue.. and I see that a lot of time is used in the getStyle.. getHeight getWidth and so on...
I try to add suggestion from the following post:
probably a problem in my application is that screen are very large.. a lot of fields....
(and using Chrome is much much better.. )
and I cannot set a fixed width / height
a Question to the developer/support ExtJS Team.. using my subscription credit.... is it possible to have a support from you in order to help me to increase performance ? I can publish my application on internet of course...
tywe make IT work for you
21 Apr 2010 12:35 AM #7
http://en.wikipedia.org/wiki/Minific...programming%29 "the process of removing all unnecessary characters from source code, without changing its functionality"
21 Apr 2010 1:57 AM #8
I have moved from Firebug to Chrome Developer Tools to debug/analyze my code, and up to now I haven't looked back.
21 Apr 2010 2:24 AM #9
I can suggest rockstarapps for compressing source in IDE on-the-flight, it's the simplest way to get it.
21 Apr 2010 6:20 AM #10
"Minifying" reduces transmission time, nothing more. "GZip" encoding of the HTML transfer, which can be requested using an HTML header, is usually far more effective ... if both the browser and the server in question support it.
If the application is "noticeably slow," that will invariably turn out to be a logic problem, not something that can be addressed by "minifying" the source-code.
It's also most reasonable to assume that the "slowdown" is caused by timing... by restarts, by timeouts, and by other similar timing-related issues in which the software will probably be seen to be idle most of the time (not "100% busy"). Modern CPUs, even on the most humble laptop, perform at blistering speeds.