Load the value of an entity field type in another form I have created a custom field and I wish to load the value dynamically in another form in relation to the specific node entity the value belongs to.
I understand that to get the value I have to use/know the field_name like this

$entity-&gt;get('field_name')-&gt;getValue();


What I want is to get the field_name set via content configurations with only the type of node and the field name as defined in the fieldItem Plugin

$field_definitions = \Drupal::service('entity_field.manager')-&gt;getFieldStorageDefinitions('node');


When I dump $field_definitions am able to see all the fields array with all the details but I can't get my node.field_name in relation to the fieldItem name defined in the specific field plugin, in my case field_custom_example

/**
 * Plugin implementation of the 'field_custom_example' field type.
 *
 * @FieldType(
 *   id = "field_custom_example",
 *   label = @Translation("Custom Example"),
 *   description = @Translation("Stores data for Custom Example Field"),
 *   default_widget = "custom_example_widget",
 *   default_formatter = "custome_example_formatter"
 * )
 */


that's where am stuck.
Use the method FieldDefinitionInterface::getType:


  Returns the field type.
  
  Return value
  
  (string) The field type, i.e. the id of a field type
  plugin. For example 'text'.


In your case for example:

foreach ($field_definitions as $name =&gt; $definition) {
  if ($definition-&gt;getType() == 'field_custom_example') {
    // found field $name
  }
}