Same name in other branches
- 5.0.x advagg_ext_minify/src/EventSubscriber/MinificationSubscriber.php \Drupal\advagg_ext_minify\EventSubscriber\MinificationSubscriber::isEnabled()
- 6.0.x advagg_ext_minify/src/EventSubscriber/MinificationSubscriber.php \Drupal\advagg_ext_minify\EventSubscriber\MinificationSubscriber::isEnabled()
- 8.x-4.x advagg_ext_minify/src/EventSubscriber/MinificationSubscriber.php \Drupal\advagg_ext_minify\EventSubscriber\MinificationSubscriber::isEnabled()
Check if the external minifier is enabled & configured for this asset type.
Paramètres
string $type: The asset type.
Return value
bool Whether to run the external minifier or not.
2 calls to MinificationSubscriber::isEnabled()
- MinificationSubscriber::minifyCss dans advagg_ext_minify/
src/ EventSubscriber/ MinificationSubscriber.php - Pass the minification over to the minification service.
- MinificationSubscriber::minifyJs dans advagg_ext_minify/
src/ EventSubscriber/ MinificationSubscriber.php - Pass the minification over to the minification service.
Fichier
-
advagg_ext_minify/
src/ EventSubscriber/ MinificationSubscriber.php, line 91
Classe
- MinificationSubscriber
- Subscribe to asset optimization events and minify assets.
Namespace
Drupal\advagg_ext_minify\EventSubscriberCode
protected function isEnabled($type) {
if (!$this->config
->get("{$type}_enabled")) {
return FALSE;
}
if (!$this->config
->get("{$type}_cmd")) {
return FALSE;
}
return TRUE;
}