public Renderer::mergeBubbleableMetadata(array $a, array $b)
Merges the bubbleable rendering metadata o/t 2nd render array with the 1st.
array $a: A render array.
array $b: A render array.
array The first render array, modified to also contain the bubbleable rendering metadata of the second render array.
Overrides RendererInterface::mergeBubbleableMetadata
\Drupal\Core\Render\BubbleableMetadata
public function mergeBubbleableMetadata(array $a, array $b) { $meta_a = BubbleableMetadata::createFromRenderArray($a); $meta_b = BubbleableMetadata::createFromRenderArray($b); $meta_a->merge($meta_b)->applyTo($a); return $a; }
© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/core!lib!Drupal!Core!Render!Renderer.php/function/Renderer::mergeBubbleableMetadata/8.1.x