Returns AJAX commands to load in-place editors' attachments.
Given a list of in-place editor IDs as POST parameters, render AJAX commands to load those in-place editors.
\Drupal\Core\Ajax\AjaxResponse The Ajax response.
public function attachments(Request $request) {
$response = new AjaxResponse();
$editors = $request->request
->get('editors');
if (!isset($editors)) {
throw new NotFoundHttpException();
}
$editorSelector = $this->container
->get('edit.editor.selector');
$elements['#attached'] = $editorSelector
->getEditorAttachments($editors);
drupal_process_attached($elements);
return $response;
}