You are here

public function TBMegaMenuBuilder::getBlockConfig in The Better Mega Menu 8

Same name and namespace in other branches
  1. 2.x src/TBMegaMenuBuilder.php \Drupal\tb_megamenu\TBMegaMenuBuilder::getBlockConfig()

Get the configuration of blocks.

Parameters

string $menu_name: Menu Machine name.

string $theme: Theme machine name.

Return value

array The block config array

Overrides TBMegaMenuBuilderInterface::getBlockConfig

File

src/TBMegaMenuBuilder.php, line 81

Class

TBMegaMenuBuilder
Defines a TBMegaMenuBuilder.

Namespace

Drupal\tb_megamenu

Code

public function getBlockConfig(string $menu_name, string $theme) {
  $menu = self::getMenus($menu_name, $theme);
  return $menu ? $menu
    ->getBlockConfig() : [];
}