Same name in other branches
  1. 5.0.x advagg_mod/src/EventSubscriber/InitSubscriber.php \Drupal\advagg_mod\EventSubscriber\InitSubscriber::getSubscribedEvents()
  2. 6.0.x advagg_mod/src/EventSubscriber/InitSubscriber.php \Drupal\advagg_mod\EventSubscriber\InitSubscriber::getSubscribedEvents()
  3. 8.x-2.x advagg_bundler/src/EventSubscriber/InitSubscriber.php \Drupal\advagg_bundler\EventSubscriber\InitSubscriber::getSubscribedEvents()
  4. 8.x-2.x advagg_mod/src/EventSubscriber/InitSubscriber.php \Drupal\advagg_mod\EventSubscriber\InitSubscriber::getSubscribedEvents()
  5. 8.x-4.x advagg_mod/src/EventSubscriber/InitSubscriber.php \Drupal\advagg_mod\EventSubscriber\InitSubscriber::getSubscribedEvents()

File

advagg_mod/src/EventSubscriber/InitSubscriber.php, line 100

Class

InitSubscriber
Perform initialization tasks for advagg_mod.

Namespace

Drupal\advagg_mod\EventSubscriber

Code

public static function getSubscribedEvents() {
    return [
        KernelEvents::REQUEST => [
            'onEvent',
            0,
        ],
        KernelEvents::RESPONSE => [
            [
                'deferCss',
                0,
            ],
            [
                'deferJs',
                0,
            ],
            [
                'asyncJs',
                0,
            ],
        ],
        AssetOptimizationEvent::CSS => [
            'translateCss',
            0,
        ],
        AssetOptimizationEvent::JS => [
            'removeConsoleLog',
            -10,
        ],
    ];
}