Skip to content

Instantly share code, notes, and snippets.

@mstrelan
Created December 24, 2021 04:21
Show Gist options
  • Save mstrelan/7c0fde1c077b765aae9f8b5a38458089 to your computer and use it in GitHub Desktop.
Save mstrelan/7c0fde1c077b765aae9f8b5a38458089 to your computer and use it in GitHub Desktop.
Taming webform configuration
<?php
// Disable promotion on /admin/structure/webform.
$config['webform.settings']['ui']['promotions_disabled'] = TRUE;
// Disable requirements warnings all over /admin/reports/status.
$config['webform.settings']['requirements']['cdn'] = FALSE;
$config['webform.settings']['requirements']['spam'] = FALSE;
// Disable misc clutter / weirdness.
$config['webform.settings']['ui']['video_display'] = 'hidden';
$config['webform.settings']['ui']['description_help'] = FALSE;
$config['webform.settings']['ui']['help_disabled'] = TRUE;
$config['webform.settings']['ui']['support_disabled'] = TRUE;
<?php
# drush php:script webform-state.php
\Drupal::state()->set('webform.element.message', [
'webform.help.installation' => TRUE,
]);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment