Automated Drupal 11 compatibility fixes

Yesterday, I received the first "Automated Drupal 11 compatibility fixes" email from the Rector-powered Project Update Bot.

It was for the Feature Toggle Twig module that adds a featureIsEnabled() function to Twig to check if a feature toggle is enabled.

For example:

{% if featureIsEnabled('foo') %}
  {# ... #}
{% endif %}

What Changes Were Needed?

The only change needed to make the module Drupal 11 compatible was updating the core_version_requirement to ^10 || ^11 - allowing the module to support Drupal 10 and 11 at the same time as it uses no deprecated code.

That's a great thing about modern Drupal compared to legacy versions - no major changes or rewrites to support a new major version!

Here's the Thing

I thought this was a great initiative in previous versions and I'm glad to see it again for Drupal 11, and it's great that it's being done with time before the Drupal 11 release as it gives maintainers the time to update their projects so as many modules as possible will be Drupal 11-compatible when it's released.

I look forward to getting more of these emails for my other contributed projects on Drupal.org.

- Oliver

Was this interesting?

Sign up here and get more like this delivered straight to your inbox every day.

About me

Picture of Oliver

I'm an Acquia-certified Drupal Triple Expert with 17 years of experience, an open-source software maintainer and Drupal core contributor, public speaker, live streamer, and host of the Beyond Blocks podcast.