v1/vendor/chi-teck/drupal-code-generator/templates/hook/views_analyze.twig

13 lines
406 B
Twig

/**
* Implements hook_views_analyze().
*/
function {{ machine_name }}_views_analyze(\Drupal\views\ViewExecutable $view) {
$messages = [];
if ($view->display_handler->options['pager']['type'] == 'none') {
$messages[] = Drupal\views\Analyzer::formatMessage(t('This view has no pager. This could cause performance issues when the view contains many items.'), 'warning');
}
return $messages;
}