Bug #56233

Epic #55575: Streamline JavaScript Code in the TYPO3 Backend

Load order of js files differs

Added by Daniel Siepmann over 7 years ago. Updated over 6 years ago.

Should have
Target version:
Start date:
Due date:
% Done:


Estimated time:
TYPO3 Version:
PHP Version:
Is Regression:
Sprint Focus:


There is a difference of ordering for js files, in case they are compressed / concatenated or not.
Looks like pagerenderer inverses the "forceOnTop files" while the ResourceCompressor doesn't.

if ($properties['forceOnTop']) {
    if ($properties['section'] === self::PART_HEADER) {
        $jsFiles = $tag . LF . $jsFiles;
    } else {
        $jsFooterFiles = $tag . LF . $jsFooterFiles;
} else {
    if ($properties['section'] === self::PART_HEADER) {
        $jsFiles .= LF . $tag;
    } else {
        $jsFooterFiles .= LF . $tag;

Instead of prepanding the file we should use the same logic as in ResourceCompressor. We should build arrays for each kind of section and merge them at the end.

The change of order should be communicated on launch. That's a breaking change for JS developers. They have to check the order of there JS files.

Related issues

Is duplicate of TYPO3 Core - Bug #53116: concatenateJs in conjunction with forceOnTopClosed2013-10-25


Updated by Daniel Siepmann over 7 years ago

Getting deeper, it looks like pagerenderer is right and Compressor should take care of forceOnTop. Currently this setting is just ignored.


Updated by Markus Klein over 7 years ago

Wait a bit, there's already a patch of mine pending I guess.


Updated by Markus Klein over 7 years ago

  • Target version deleted (6.2.0)

Duplicate of #53116.

Merged in 6.1 and 6.2.

We've to ask the release managers whether backports to < 6.1 are allowed.

But wait a bit, if you intend to use this on any other version, as a patch for #56242 is pending.


Updated by Daniel Siepmann over 7 years ago

  • Parent task set to #55575

Updated by Benni Mack over 6 years ago

  • Status changed from New to Closed

Also available in: Atom PDF