You are here

public static function Ds::layoutExists in Display Suite 8.4

Same name and namespace in other branches
  1. 8.3 src/Ds.php \Drupal\ds\Ds::layoutExists()

Check if a layout exists or not.

Parameters

$id: The layout plugin id.

Return value

bool Whether the layout exists or not.

1 call to Ds::layoutExists()
ds_entity_view_alter in ./ds.module
Implements hook_entity_view_alter().

File

src/Ds.php, line 120

Class

Ds
Helper class that holds all the main Display Suite helper functions.

Namespace

Drupal\ds

Code

public static function layoutExists($id) {
  $layouts = self::getLayouts();
  return isset($layouts[$id]) ? TRUE : FALSE;
}