If you create a new field on an entity in the Drupal backend, the field name usually get's always prefixed with "field_". If you are like me and trust in the powers from above, you may have taken this for granted for a long time ...
Until someday I installed Commerce Kickstart distribution and wondered why the field names do not get prefixed there. First I did not directly see the coincedence on Commerce Kickstart, but just thought it might have been a wonder from above. Now I started the same project again without Commerce Kickstart and wondered why the 'field_' prefix was there again. This was finally the time I got curious about that and noticed that the field_ui module from Drupal Core comes with a setting for this: https://git.drupalcode.org/project/drupal/-/blob/81df3e9c1792b9ca08693f6...
Now Commerce Kickstart is changing this to not prefix: https://git.drupalcode.org/project/commerce_kickstart/-/blob/43780ce8ae8...
And so can you do on your own project:
Use a field_ui.settings.yml with just
field_prefix: ''
Neuen Kommentar schreiben