public function SlickDevelSettingsForm::submitForm in Slick extras 8
Implements \Drupal\Core\Form\FormInterface::submitForm().
Overrides ConfigFormBase::submitForm
File
- slick_devel/
src/ SlickDevelSettingsForm.php, line 113
Class
- SlickDevelSettingsForm
- Defines the Slick admin settings form.
Namespace
Drupal\slick_develCode
public function submitForm(array &$form, FormStateInterface $form_state) {
$this->configFactory
->getEditable('slick_devel.settings')
->set('unminified', $form_state
->getValue('unminified'))
->set('debug', $form_state
->getValue('debug'))
->set('replace', $form_state
->getValue('replace'))
->set('disable', $form_state
->getValue('disable'))
->save();
// Invalidate the library discovery cache to update new assets.
$this->libraryDiscovery
->clearCachedDefinitions();
$this->configFactory
->clearStaticCache();
parent::submitForm($form, $form_state);
}