You are here

function draggable_dashboard_page_attachments_alter in Draggable dashboard 8

Implements hook_page_attachments_alter().

File

./draggable_dashboard.module, line 105
Contains draggable_dashboard.module.

Code

function draggable_dashboard_page_attachments_alter(array &$attachments) {
  $request = \Drupal::request();
  if ($request
    ->get('_route') == 'block.admin_library' && strpos($request
    ->get('region'), 'draggable_dashboard') === 0) {
    $attachments['#attached']['library'][] = 'draggable_dashboard/draggable_dashboard.main';
  }
}