-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathext_localconf.php
25 lines (18 loc) · 919 Bytes
/
ext_localconf.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
<?php
use FelixNagel\FePerformance\Utility\ExtensionConfigurationUtility;
use FelixNagel\FePerformance\Hook\JavaScriptCompressHandlerHook;
use FelixNagel\FePerformance\Hook\RenderPreProcessHook;
defined('TYPO3') || die();
$emConfig = ExtensionConfigurationUtility::get();
if ($emConfig['minifyJavaScript']) {
// Add hook for minification
// @extensionScannerIgnoreLine
$GLOBALS['TYPO3_CONF_VARS']['FE']['jsCompressHandler'] = JavaScriptCompressHandlerHook::class . '->process';
// Make sure page JS is not minified before
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_div.php']['minifyJavaScript'] = null;
}
if ($emConfig['excludeInlineJsFromConcatenation']) {
// Move and do not merge per page added inline JS
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_pagerenderer.php']['render-preProcess'][] =
RenderPreProcessHook::class . '->process';
}