You are here

public function AssetCollectionOptimizerInterface::optimize in Zircon Profile 8.0

Same name and namespace in other branches
  1. 8 core/lib/Drupal/Core/Asset/AssetCollectionOptimizerInterface.php \Drupal\Core\Asset\AssetCollectionOptimizerInterface::optimize()

Optimizes a collection of assets.

Parameters

array $assets: An asset collection.

Return value

array An optimized asset collection.

2 methods override AssetCollectionOptimizerInterface::optimize()
CssCollectionOptimizer::optimize in core/lib/Drupal/Core/Asset/CssCollectionOptimizer.php
The cache file name is retrieved on a page load via a lookup variable that contains an associative array. The array key is the hash of the file names in $css while the value is the cache file name. The cache file is generated in two cases. First, if…
JsCollectionOptimizer::optimize in core/lib/Drupal/Core/Asset/JsCollectionOptimizer.php
The cache file name is retrieved on a page load via a lookup variable that contains an associative array. The array key is the hash of the names in $files while the value is the cache file name. The cache file is generated in two cases. First, if…

File

core/lib/Drupal/Core/Asset/AssetCollectionOptimizerInterface.php, line 23
Contains \Drupal\Core\Asset\AssetCollectionOptimizerInterface.

Class

AssetCollectionOptimizerInterface
Interface defining a service that optimizes a collection of assets.

Namespace

Drupal\Core\Asset

Code

public function optimize(array $assets);