Implements \Drupal\Core\Form\FormInterface::buildForm().
Overrides SystemConfigFormBase::buildForm
public function buildForm(array $form, array &$form_state) {
$config = $this->configFactory
->get('statistics.settings');
// Content counter settings.
$form['content'] = array(
'#type' => 'details',
'#title' => t('Content viewing counter settings'),
);
$form['content']['statistics_count_content_views'] = array(
'#type' => 'checkbox',
'#title' => t('Count content views'),
'#default_value' => $config
->get('count_content_views'),
'#description' => t('Increment a counter each time content is viewed.'),
);
return parent::buildForm($form, $form_state);
}