Same name in other branches
  1. 6.0.x src/Asset/AssetOptimizationEvent.php \Drupal\advagg\Asset\advagg_optimization_event
  2. 8.x-3.x src/Asset/AssetOptimizationEvent.php \Drupal\advagg\Asset\advagg_optimization_event
  3. 8.x-4.x src/Asset/AssetOptimizationEvent.php \Drupal\advagg\Asset\advagg_optimization_event

The Asset Optimization Event provides 2 separate events, one for JavaScript and one for CSS optimization. Both provide equivalent data and is only separated to allow easy differentiation/choice of events to subscribe to.

The AssetOptimizationEvent::JS is fired by \Drupal\advagg\Asset\JsOptimizer, The AssetOptimizationEvent:CSS is fired by \Drupal\advagg\Asset\CssOptimizer.

There are multiple examples within the Advanced Aggregates submodules of subscribing to one or both of the events.

Fichier

src/Asset/AssetOptimizationEvent.php, line 7

Classes