code: public function getFieldInstance($field_name)
      {
          $field_name = $this->getFieldNameByLocator($field_name);
  
          return empty($this->instances[$field_name]) ? [] : $this->instances[$field_name];
      }
docs: @param string $field_name
  Machine name or label of a field.
  
  @return array[]
  Drupal field definition.