You are here

public function ThemeHandlerInterface::install in Drupal 8

Installs a given list of themes.

Parameters

array $theme_list: An array of theme names.

bool $install_dependencies: (optional) If TRUE, dependencies will automatically be installed in the correct order. This incurs a significant performance cost, so use FALSE if you know $theme_list is already complete and in the correct order.

Return value

bool Whether any of the given themes have been installed.

Throws

\Drupal\Core\Extension\ExtensionNameLengthException Thrown when the theme name is to long.

Deprecated

in drupal:8.0.0 and is removed from drupal:9.0.0. Use the theme_installer service instead.

See also

https://www.drupal.org/node/3017233

\Drupal\Core\Extension\ThemeInstallerInterface::install()

1 method overrides ThemeHandlerInterface::install()
ThemeHandler::install in core/lib/Drupal/Core/Extension/ThemeHandler.php
Installs a given list of themes.

File

core/lib/Drupal/Core/Extension/ThemeHandlerInterface.php, line 32

Class

ThemeHandlerInterface
Manages the list of available themes.

Namespace

Drupal\Core\Extension

Code

public function install(array $theme_list, $install_dependencies = TRUE);