public AjaxResponse::addCommand(CommandInterface $command, $prepend = FALSE)
Add an AJAX command to the response.
Parameters
\Drupal\Core\Ajax\CommandInterface $command: An AJAX command object implementing CommandInterface.
bool $prepend: A boolean which determines whether the new command should be executed before previously added commands. Defaults to FALSE.
Return value
AjaxResponse The current AjaxResponse.
File
core/lib/Drupal/Core/Ajax/AjaxResponse.php, line 38
Class
AjaxResponse JS