Jump to content

IPS should combine javascript/CSS?


Lukeroge

Recommended Posts

Posted

Right now IPS includes a rather large amount of JS and CSS on every page, and a decent amount of it could be combined into a single file and minified, as a best practice. 

It would be nice to have this happen automatically, or for IPS to include an ACP option to enable it.

Posted

I was thinking something similar. The CSS can be consolidated and organized better. I find myself looking through source more often to find codes that should be easily found in the files. There are category of codes that are split into other files when they can be managed more efficiently if they're grouped in the same file.

  • 2 weeks later...
  • 7 months later...
Posted

The same question.

When loading page, my browser sending a number of HTTP requests for js and css, which takes some time.

Why not compile root js and css to one file and save it to cache for reducing number of requests? Root js and css loads on every page loading.

Answer from IPS Staff will be very appreciated.

Posted

There are some that they could merge, but a lot of merging has already happened. Most of the files that you get at the moment are for different parts of the site, so there's no point bundling the gallery JS with the forum JS, because you wouldn't use them at the same time. There's also not point bundling the forum JS with core JS when viewing the forum, and the gallery JS with core when viewing the gallery, because that means that all the core JS will have to be redownloaded when you change from the forum to the gallery.

In dev mode, when JS isn't merged, there are about 250 JS files requested. In production, it's about 20 files. It's much better than it could be.

Posted
7 hours ago, Colonel_mortis said:

There are some that they could merge, but a lot of merging has already happened. Most of the files that you get at the moment are for different parts of the site, so there's no point bundling the gallery JS with the forum JS, because you wouldn't use them at the same time. There's also not point bundling the forum JS with core JS when viewing the forum, and the gallery JS with core when viewing the gallery, because that means that all the core JS will have to be redownloaded when you change from the forum to the gallery.

In dev mode, when JS isn't merged, there are about 250 JS files requested. In production, it's about 20 files. It's much better than it could be.

This makes total sense. I can live with this and I am glad someone finally shed some light on this. Thanks, Colonel.

Posted

The other thing to remember with HTTP 2 (must use ssl fyi) the browser doesnt use multiple connections to each asset so it will load pretty fast naturally.

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...