Issue Feature Under Review

#109209Add ModifyLoadedUserTsConfigEvent (similar to ModifyLoadedPageTsConfigEvent)

Thomas Rawiel 03/11/26, 18:57 updated 11/14/26, 18:23

Description

UserTsConfig is loaded in this order (if uncached)
  1. BeforeLoadedUserTsConfigEvent
  2. user.tsconfig from installed packages
  3. TSconfig from backend user groups
  4. TSconfig from the backend user

Before TYPO3 v14 it was possible to modify the resulting UserTSconfig after loading by using
ExtensionManagementUtility::addUserTSConfig(). This allowed extensions to adjust the final configuration using operators such as addToList() or removeFromList().

With the removal of that function, this approach is no longer possible in the same way, as far as I can tell.

Proposal :
Introduce a new PSR-14 event: ModifyLoadedUserTsConfigEvent
as a final step after the complete UserTSconfig has been assembled, similar to ModifyLoadedPageTsConfigEvent.

Proposed loading order:
  1. BeforeLoadedUserTsConfigEvent
  2. user.tsconfig from installed packages
  3. TSconfig from backend user groups
  4. TSconfig from the backend user
  5. ModifyLoadedUserTsConfigEvent

This would allow extensions to safely modify the final configuration.

Use case:
In our extension we dynamically add UserTSconfig depending on the loaded TCA.

For example, we add custom doktype icons to the page tree drag area:

options.pageTree.doktypesToShowInNewPageDragArea := addToList(<doktypes>)

Previously this was done in BootCompletedEvent via ExtensionManagementUtility::addUserTSConfig(…)
This ensured that our configuration was applied after other extensions or user/group TSconfig potentially modified the same setting.
With the current loading sequence in TYPO3 v14, there is no reliable extension point to modify the fully assembled UserTSconfig.

Introducing ModifyLoadedUserTsConfigEvent would provide a clean and consistent solution, analogous to the existing ModifyLoadedPageTsConfigEvent.

Reviews 1

History 12