// Assume there is a form with an element named 'my_field'. $form_state->getBuildInfo()['my_field']['#value'];
// Assume there is a form with an element named 'my_field'. $form_state->set(['my_field' => 'new_value']);
// Assume there is a form with an element named 'my_field'. $form_state->getBuildInfo()['my_field'];This code retrieves the properties of the 'my_field' element in the form. The package library for FormStateInterface is Drupal\Core\Form.