Bug #85867
Updated by Kevin Appelt over 6 years ago
There seems to be a problem with the new import syntax (in the current dev-master) if you use it in ext_localconf.php.
<pre>
TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addPageTSConfig(
'@import \'EXT:myextension/Configuration/TsConfig/Page.tsconfig\''
);
TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addUserTSConfig(
'@import \'EXT:myextension/Configuration/TsConfig/User.tsconfig\''
);
</pre>
The part with addPageTSConfig is the flaky part. The method addUserTSConfig is working as expected.
The same import with the old syntax is working as expected.
This is what i can see in the backend (whole line is dark red like all [global] lines):
<pre>
[GLOBAL]### @import 'EXT:myextension/Configuration/TsConfig/Page.tsconfig' begin ###
</pre>
followed by the imported code (which has working @includes) which gets completely ignored.
Same problem if i add a new line in front of it like so:
<pre>
TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addPageTSConfig(
'
@import \'EXT:myextension/Configuration/TsConfig/Page.tsconfig\''
);
</pre>
So solve the problem I have to add a random line in front of the @import - like so:
<pre>
TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addPageTSConfig(
'thisisfordebuggingreasons = 1
@import \'EXT:myextension/Configuration/TsConfig/Page.tsconfig\''
);
</pre>
with this result (yes, no new line before the ###)
<pre>
[GLOBAL]
thisisfordebuggingreasons = 1### @import 'EXT:myextension/Configuration/TsConfig/Page.tsconfig' begin ###
</pre>
again followed by the imported code (which has working @includes) which get not ignored now.