Updating field values in Drupal 8 and 9
When you have to modify the values of the fields by code, there are several ways to do it. The most typical one: $entity->field_name->value = 'foo' $entity->field_name->target_id = 123 but it is the same as doing: $entity->field_name = 'foo' $entity->field_name = 123 That's a shorter way to write the same...
Have Any Project in Mind?
If you want to do something in Drupal maybe you can hire me.
Either for consulting, development or maintenance of Drupal websites.