Why is webform submit handler not working in form alter? webform submit handler not calling in form alter. I have tried solutions like
   use Drupal\Core\Form\FormStateInterface;

function MODULENAME_form_alter(&amp;$form,$form_state, $form_id) {
  if ($form_id == 'FORMID') {
    $form['actions']['submit']['#submit'][] = 'MODULENAME_form_submit';
  }
}

function MODULENAME_form_submit($form, FormStateInterface $form_state) {
  print_r($form_state);
} 


But this one is not working. Any help?
Maybe you can try this : 

  function MODULENAME_form_alter(&amp;$form,$form_state, $form_id) {
    if ($form_id == 'FORMID') {
      foreach (array_keys($form['actions']) as $action) {
        if ($action != 'preview' &amp;&amp; isset($form['actions'][$action]['#type']) &amp;&amp; $form['actions'][$action]['#type'] === 'submit') {
          $form['actions'][$action]['#submit'][] = 'MODULENAME_form_submit';
        }
      }
    }
  }

  function MODULENAME_form_submit($form, FormStateInterface $form_state) {
    kint($form_state);
  }