public function helpPage($name) { $build =
[];
if ($this->
moduleHandler()->
hasImplementations('help',
$name)) { $module_name =
$this->
moduleHandler()->
getName($name);
$build['#title'
] =
$module_name;
$info =
$this->moduleExtensionList->
getExtensionInfo($name);
if ($info[ExtensionLifecycle::LIFECYCLE_IDENTIFIER
] === ExtensionLifecycle::EXPERIMENTAL
) { $this->
messenger()->
addWarning($this->
t('This module is experimental. <a href=":url">Experimental modules</a> are provided for testing purposes only. Use at your own risk.',
[':url' => 'https://www.drupal.org/core/experimental'
]));
} $temp =
$this->
moduleHandler()->
invoke($name, 'help',
["help.page.
$name",
$this->routeMatch
]);
if (empty($temp)) { $build['top'
] =
['#markup' =>
$this->
t('No help is available for module %module.',
['%module' =>
$module_name])];
} else { if (!
is_array($temp)) { $temp =
['#markup' =>
$temp];
}