cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Decrease Combined JS file downnload time

Decrease Combined JS file downnload time

Hello again everyone ,

I have done some debugging on my PC, and it looks like the Combined.6.0.3-b21.20150715.js file is taking ~20 seconds to download upon initial load. I know that this is more of a platform architecture question, but is it possible to break this file apart and have multiple calls made in parallel to increase performance?

Has anyone had this experience and managed to increase the performance?

11 REPLIES 11

Re: Decrease Combined JS file downnload time

This is an item that development is actually looking at to improve.

Re: Decrease Combined JS file downnload time

Hi,

i have the same issue. The performance ist really bad. We have a couple of customized widgets in our application and the filesize of js and css grows.
Is it possible minify the files? Some other performance tipps?

Best regards

Re: Decrease Combined JS file downnload time

Well, dividing the js/css in multiple files will end up on a worst performance, it's better to download one big file than a lot of small ones.

I don't know, but maybe the server doesn't has compact files enabled, as HTTP servers can serve pages compacted ( zip ) then transfer will be faster.

Carles.

Re: Decrease Combined JS file downnload time

Hi Carles,

if i do understand that right there is always a big combined js/css file with code from all widgets regardless of the widget is used on this page or not. So if you have 20 customized widgets, you will always download this big file on every page. Ok, next time it will be cached.

Performance is not equal to download time. The size of css and js is crucial for rendering performance.

Correct me if i'm wrong.

Re: Decrease Combined JS file downnload time

Hi Juri,

In that part I don't have much expertise now, sorry I can't say more ( my last big development in js was on 1999/2000... ).

Carles.

Highlighted

Re: Decrease Combined JS file downnload time

Combining Javascript and CSS is standard practice to improve initial download performance. The time cost of separate requests is well beyond any benefit of parallelism or "lazy loading" strategies. Browser thread limits and blocking dependencies make sep. requests even worse. Compression on combined files make it even better.

The application is the sum of its parts including all widgets, styles, extensions.

You can avoid making more demands on throughput by avoiding individual widget custom styles, especially when used in repeaters. That is one time where things are downloaded as needed, because it applies to individual elements.

@Juri : app is a one time download per browser until you clear cache.

Re: Decrease Combined JS file downnload time

Yeah, download time is one thing, performance specialy rendering performance an another. ThingWorx is not a SPA or am i wrong? Then why do i have to handle (and also download) stuff i dont need on one site?

Are there any tutorials or documents how i can optimize the performance? My aim is to get under 1 second and i'm far away from that. For example i would like to minify my sources at first.

Re: Decrease Combined JS file downnload time

Hi Juri, what's SPA?

1 second when? first load? you won't get there with Standard TW Mashups, if you need this, you will have to work with TW REST API and build your own Web Interface.

Carles.

Re: Decrease Combined JS file downnload time

I agree with Carles- Use the Thingworx API to create a special-purpose SPA (Single Page App) if you have such a performance requirement.