Blog items

A default value can be set for fields that are attached to a content type (i.e., any field-able entity). The entered value is used to pre-fill the form (i.e., entity) when creating new content. Although having a static starting value is often perfectly fine, true power comes when these values can be set dynamically.

As a developer, I strive to deliver high-quality code that is understandable for other developers and is as future proof as it can be. For me, this is an ongoing learning process in the way code is written, and tools that can be used to assist me. Many different sources can be found with opinionated instructions on how to write "perfect" code.

By now, every Drupal developer should know that it's a bad idea to overwrite core and contributed code. Especially when using Composer correctly and, therefore, only store the composer.lock file to the version control system. It should be imminent that changing files containing core code is a no-brainer (don't hack core!).

When writing custom forms, you are often asked to add an extra paragraph of text between input fields. A solution that is used a lot is: