function drush_layout_plugin_region_list in Layout Plugin (obsolete, use core's Layout Discovery) 8
Create a basic template and configuration file for a new Display Suite layout.
File
- ./
layout_plugin.drush.inc, line 64 - Drush integration.
Code
function drush_layout_plugin_region_list($name = NULL) {
$layoutsManager = \Drupal::service('plugin.manager.layout_plugin.region');
/** @var $layoutsManager \Drupal\layout_plugin\Plugin\LayoutRegion\LayoutRegionPluginManager */
$plugins = $layoutsManager
->getDefinitions();
foreach ($plugins as $id => $pluginInfo) {
$plugin = $layoutsManager
->createInstance($id, array());
/** @var $plugin \Drupal\layout_plugin\Plugin\Layout\LayoutInterface */
drush_print(dt('Layout region !id could be loaded.', array(
'!id' => $id,
)));
}
}