際際滷

際際滷Share a Scribd company logo
How to bring your idea to life
and foster adoption by the
community
I Have a Great Idea
For a Drupal Module!
Now What?
Martin Anderson-Clutz
@mandclu
Martin
Anderson-Clutz
@mandclu
@mandclu@drupal.community
This Talk
 Based on my own experience, YMMV
 Intended to help you better define what your module should do,
and why
 A resource guide
 Amount of code === NULL
The BIG IDEA
 What problem are you trying to solve?
 Jakobs Law
 What mental models exist in the space?
 Toolkit vs. Solutions
 Sometimes both are needed!
Proof of Concept (optional)
 Implement the simplest possible, core idea of what you want to achieve
 Hard code values initially
 A great way to test the overall concept, and collect early feedback
 Motivating to see your idea take shape
I have a Great Idea for a Drupal Module! Now What? - DrupalDevDays 2023
Research
 Does this already exist? What similar modules are available?
 Could a library get me part way?
 Search drupal.org (and google), use synonyms
 Could this be a new feature on an existing module?
 Are there analogous modules I can use for reference?
 Is there an abandoned project I could take over?
Plan
 What functionality is needed?
 User stories?
 What should be configurable?
 What existing functionality can I extend?
 Identify classes or hooks
 What needs to be stored?
 Config or content entities?
 Or DB tables?
<code>
Writing Your Code
 Free tools available
 VS Code for Drupal
 Coding standards are important
 Lint as you go
 Write automated tests
 Test-Driven Development
 Drush generators
 Generate entity
 Get feedback early and often
Get Help
 Your local DUG
 Slack: #module-development
 Contrib Half Hour
 Forums or Stack exchange
 Collaborators?
Your Drupal.org Project
 Start as a sandbox
 Promote to full project when it's ready to share
 Lint!
 Use the README template
Your Drupal.org Project Page
 Suggested content
 Describe the problem youre trying to solve
 List key features
 Similar Modules
 How is yours different?
 Fancy logo?
 Screen captures
Releases
 Start by doing a smaller number of things really well
 Stable releases!
 Grow features over time
 Listen to user feedback
 Creating a release
 Alpha, beta, etc.
 Semantic versioning
 Opt into security coverage
Spread the Word
 The Weekly Drop
 Maybe wait until stable, or at least beta
 Blog about it
 Get involved in relevant Slack channels
 Find other people with the problem you started out to solve
 Present!
 DUGs and camps love new content
 Talking Drupal podcast - Module of the Week
Maintainership
 Be the maintainer you wish all modules had
 Be responsive
 Make releases
 Write documentation
 Collaborate
 An opportunity to be the boss
 Follow your passion
 Learn!
Smart Date
Origin Story
 Initial idea ~2009
 Bring calendar conventions to Drupal, esp duration concept
 Decided to create a module in early 2019
 Researched existing solutions
 Found some, reached out
 Missed some, discussions later
Need For A Field, Module
Editor UX
Performance
Formatting
Timeline
 Apr 3 2019 - sandbox: Timestamp ranges
 Apr 18 - project: Smart Date
 Apr 19 - alpha1 release
 May 6 - beta1
 other releases ...
 May 24 - blog, beta6
 May 30 - The Weekly Drop
Timeline
 Jun 10 - Decided output structure translation was a stable blocker
 Jun 19 - rc1 release added custom config entities
 Jul 4 - Fullcalendar View patch to support Smart Date
 Jul 11 - Stable 1.0 release!
 Jul 12 - blog: Smart Date - Time to Level Up!
 Oct 17 - Using Smart Date presentation at Waterloo DUG
 Feb 23 2020 - 2.0 - Recurring dates, timezones
 Feb 24 - blog: Smart Date 2.0: Let's Do This Again!
Timeline
 Apr 28 - 2.4 - Fullcalendar View support
 Jul 13 - 3.0 - Stable support for core date fields, theme improvements
 Aug 14 - DrupalCamp Colorado presentation
 Sep 10 - Digital Camp Atlanta presentation
 Sep 17 - Virtual Flyover Camp presentation
 Sep 21 - blog: Smart Date 3.0
 Oct 16 - BADCamp presentation
 Nov 16 - 3.1 - Recur by hour, minute - consecutive events, blog
 Nov 19 - Drupal Yorkshire presentation
Timeline
 Apr 7 2021 - DrupalNYC (DUG) presentation
 Apr 15 - 3.2 - Hide end date unless different, HTML5 time element
wrapper, drush script to migrate values from core fields
 Apr 16 - DrupalCon presentation
 May 23 - 3.3 - Inline widget for more compact display
 Aug 20 - 3.4 - Support for Date Augmenter API
 Add to Calendar Augmenter
 Link Augmenter
 Date Content Augmenter
Keys to Success
 Solved common problems
 Extended core code wherever possible
 Provided both tools and solutions
 Starter Kit, Calendar Kit
 Community contributions
 Made maintainership a focus
 Listening to what users need
 Promoted through blogs, The Weekly Drop,
presentations
Additional Resources
 Drupalize.me Drupal Module Development Guide
 Managing a drupal.org theme, module, or distribution project - Drupal.org
 Maintainership
 Drupal MRN - tool for making release notes
 Please publish a stable release - sullice.com
 Drupal slack - #maintainers
 Post questions at the Maintainer Support project
 #ddd23 TALK: Why Module Builder should be
in your developer toolkit - YouTube
Questions
Comments
@mandclu
@mandclu@drupal.community
Thank you!
@mandclu

More Related Content

I have a Great Idea for a Drupal Module! Now What? - DrupalDevDays 2023

  • 1. How to bring your idea to life and foster adoption by the community I Have a Great Idea For a Drupal Module! Now What? Martin Anderson-Clutz @mandclu
  • 3. This Talk Based on my own experience, YMMV Intended to help you better define what your module should do, and why A resource guide Amount of code === NULL
  • 4. The BIG IDEA What problem are you trying to solve? Jakobs Law What mental models exist in the space? Toolkit vs. Solutions Sometimes both are needed!
  • 5. Proof of Concept (optional) Implement the simplest possible, core idea of what you want to achieve Hard code values initially A great way to test the overall concept, and collect early feedback Motivating to see your idea take shape
  • 7. Research Does this already exist? What similar modules are available? Could a library get me part way? Search drupal.org (and google), use synonyms Could this be a new feature on an existing module? Are there analogous modules I can use for reference? Is there an abandoned project I could take over?
  • 8. Plan What functionality is needed? User stories? What should be configurable? What existing functionality can I extend? Identify classes or hooks What needs to be stored? Config or content entities? Or DB tables?
  • 10. Writing Your Code Free tools available VS Code for Drupal Coding standards are important Lint as you go Write automated tests Test-Driven Development Drush generators Generate entity Get feedback early and often
  • 11. Get Help Your local DUG Slack: #module-development Contrib Half Hour Forums or Stack exchange Collaborators?
  • 12. Your Drupal.org Project Start as a sandbox Promote to full project when it's ready to share Lint! Use the README template
  • 13. Your Drupal.org Project Page Suggested content Describe the problem youre trying to solve List key features Similar Modules How is yours different? Fancy logo? Screen captures
  • 14. Releases Start by doing a smaller number of things really well Stable releases! Grow features over time Listen to user feedback Creating a release Alpha, beta, etc. Semantic versioning Opt into security coverage
  • 15. Spread the Word The Weekly Drop Maybe wait until stable, or at least beta Blog about it Get involved in relevant Slack channels Find other people with the problem you started out to solve Present! DUGs and camps love new content Talking Drupal podcast - Module of the Week
  • 16. Maintainership Be the maintainer you wish all modules had Be responsive Make releases Write documentation Collaborate An opportunity to be the boss Follow your passion Learn!
  • 18. Origin Story Initial idea ~2009 Bring calendar conventions to Drupal, esp duration concept Decided to create a module in early 2019 Researched existing solutions Found some, reached out Missed some, discussions later
  • 19. Need For A Field, Module Editor UX Performance Formatting
  • 20. Timeline Apr 3 2019 - sandbox: Timestamp ranges Apr 18 - project: Smart Date Apr 19 - alpha1 release May 6 - beta1 other releases ... May 24 - blog, beta6 May 30 - The Weekly Drop
  • 21. Timeline Jun 10 - Decided output structure translation was a stable blocker Jun 19 - rc1 release added custom config entities Jul 4 - Fullcalendar View patch to support Smart Date Jul 11 - Stable 1.0 release! Jul 12 - blog: Smart Date - Time to Level Up! Oct 17 - Using Smart Date presentation at Waterloo DUG Feb 23 2020 - 2.0 - Recurring dates, timezones Feb 24 - blog: Smart Date 2.0: Let's Do This Again!
  • 22. Timeline Apr 28 - 2.4 - Fullcalendar View support Jul 13 - 3.0 - Stable support for core date fields, theme improvements Aug 14 - DrupalCamp Colorado presentation Sep 10 - Digital Camp Atlanta presentation Sep 17 - Virtual Flyover Camp presentation Sep 21 - blog: Smart Date 3.0 Oct 16 - BADCamp presentation Nov 16 - 3.1 - Recur by hour, minute - consecutive events, blog Nov 19 - Drupal Yorkshire presentation
  • 23. Timeline Apr 7 2021 - DrupalNYC (DUG) presentation Apr 15 - 3.2 - Hide end date unless different, HTML5 time element wrapper, drush script to migrate values from core fields Apr 16 - DrupalCon presentation May 23 - 3.3 - Inline widget for more compact display Aug 20 - 3.4 - Support for Date Augmenter API Add to Calendar Augmenter Link Augmenter Date Content Augmenter
  • 24. Keys to Success Solved common problems Extended core code wherever possible Provided both tools and solutions Starter Kit, Calendar Kit Community contributions Made maintainership a focus Listening to what users need Promoted through blogs, The Weekly Drop, presentations
  • 25. Additional Resources Drupalize.me Drupal Module Development Guide Managing a drupal.org theme, module, or distribution project - Drupal.org Maintainership Drupal MRN - tool for making release notes Please publish a stable release - sullice.com Drupal slack - #maintainers Post questions at the Maintainer Support project #ddd23 TALK: Why Module Builder should be in your developer toolkit - YouTube