You are here

function contentimport_preprocess_page in Content Import 8.3

Same name and namespace in other branches
  1. 8.9 contentimport.module \contentimport_preprocess_page()
  2. 8 contentimport.module \contentimport_preprocess_page()
  3. 8.4 contentimport.module \contentimport_preprocess_page()

Implements contentimport_preprocess_page().

File

./contentimport.module, line 11
Module file for Contentimport.

Code

function contentimport_preprocess_page(&$variables) {
  $variables['page']['#cache']['contexts'][] = 'route';
  $urlRoute = \Drupal::routeMatch()
    ->getRouteName();
  if ($urlRoute == 'contentimport.admin_settings') {
    $variables['#attached']['library'][] = 'contentimport/common-styling';
  }
}