TaxonomyMenu.php in Taxonomy menu 8.3
File
src/Controller/TaxonomyMenu.php
View source
<?php
namespace Drupal\taxonomy_menu\Controller;
use Drupal\Core\Controller\ControllerBase;
class TaxonomyMenu extends ControllerBase {
public function renderTaxonomyLinks() {
$taxonomy_menus = $this
->entityTypeManager()
->getStorage('taxonomy_menu')
->loadMultiple();
$links = [];
foreach ($taxonomy_menus as $taxonomy_menu) {
$links += $taxonomy_menu
->getLinks([]);
}
return [
'#type' => 'markup',
'#markup' => '',
];
}
}