Streamlined Workflow for Contrib Modules with Composer Dependencies

Efficient Composer Workflow for Drupal Contrib Development with Dependencies

Michael Anello outlines a Composer-based workflow for contributing to Drupal contrib projects with dependencies. For modules like Markdown Easy and Smart Trim, a direct clone into web/modules/contrib/ isn’t sufficient when Composer packages are involved. Instead, Anello recommends cloning modules into a top-level /modules directory and updating composer.json to include a "path" repository pointing to ./modules/*.

This setup allows contributors to use composer require drupal/project_name, triggering dependency resolution and symlinking into the contrib directory. The approach enables clean Composer workflows across multiple contrib projects and is a staple in Anello’s training during DrupalEasy office hours.

Reference: Method for Cloning and Working on Drupal Contrib Projects, DrupalEasy (4 September 2025)

Disclosure: This content is produced with the assistance of AI.

Disclaimer: The opinions expressed in this story do not necessarily represent that of TheDropTimes. We regularly share third-party blog posts that feature Drupal in good faith. TDT recommends Reader's discretion while consuming such content, as the veracity/authenticity of the story depends on the blogger and their motives. 

Note: The vision of this web portal is to help promote news and stories around the Drupal community and promote and celebrate the people and organizations in the community. We strive to create and distribute our content based on these content policy. If you see any omission/variation on this please reach out to us at #thedroptimes channel on Drupal Slack and we will try to address the issue as best we can.

Related Organizations

Upcoming Events

Latest Opportunities