Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. AssetCollectionGrouperInterface.php

function AssetCollectionGrouperInterface::group

Groups a collection of assets into logical groups of asset collections.

Parameters

array $assets: An asset collection.

Return value

array A sorted array of asset groups.

2 methods override AssetCollectionGrouperInterface::group()
CssCollectionGrouper::group in core/lib/Drupal/Core/Asset/CssCollectionGrouper.php
Puts multiple items into the same group if they are groupable. Items of the 'file' type are groupable if their 'preprocess' flag is TRUE, and items of the 'external' type are never groupable. Items with a media type of…
JsCollectionGrouper::group in core/lib/Drupal/Core/Asset/JsCollectionGrouper.php
Puts multiple items into the same group if they are groupable. Items of the 'file' type are groupable if their 'preprocess' flag is TRUE. Items of the 'external' type are not groupable.

File

core/lib/Drupal/Core/Asset/AssetCollectionGrouperInterface.php, line 19

Class

AssetCollectionGrouperInterface
Interface defining a service that logically groups a collection of assets.

Namespace

Drupal\Core\Asset

Code

public function group(array $assets);

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal