My theme requires multiple modules to be install before it is fully functional. How can one set module dependency in a theme, so that when a user enables the theme, it will also enable the required modules? So far, I tried to specify the dependencies in the .info file of the theme, however, no success:

dependencies[] = some_module

Any help is much appreciated.


As far as I know, this functionality doesn't exist yet (up to Drupal 7).

A feature request is already created at https://drupal.org/node/474684 (for Drupal 8).

  • And we don't expect it to be implemented as a theme should not depend on a module, as both have different purposes. – Vishal Kumar Sahu Feb 2 '19 at 20:50

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.