When to apply patterns

Events happening in the community are now at Drupal community events on www.drupal.org.
Posted by pyxio on August 14, 2012 at 11:12am

Greetings,

I am very interested in patterns. My question is what is the ideal point in a development project to start incorporating them? Can I build a prototype site completely and then create the patterns for it, or must patterns be done in concurrence with development? My apologies if the answer is obvious but I am still a little unsure how to start a project that incorporates patterns.

Thanks
Kevin

Comments

Hi, if I well understood you

Posted by shakty on August 15, 2012 at 7:43am

Hi,

if I well understood you are writing a contrib module, and you want to integrate it with Patterns, right? Good!

You can create the patterns at any time, but of course better to have your module design stable enough.

You could actually start from the end, and write an export function and try to run it.

In the current version of Patterns (beta4), you must write all the hooks (prepare, validate, params, etc.) even if your module does not actually need them. I am going to push today or tomorrow a new version, in which all these hooks are optional. In this case, you need just to implement hook_patterns.

Hope this helps a bit. If you have other doubts, don't hesitate to write! :)

Thanks for the

Posted by pyxio on August 15, 2012 at 7:58am

Thanks for the info!

Actually, rather than a contributed module I am thinking about creating a complete functional website that can be available as a distro. Should I just build the entire site first and then create a pattern that would quickly replicate it? In other words, do I need to even think about patterns yet or can I focus on the web application and functionality at this point? I am thinking there is great potential using patterns and the aegir hosting system. Do you have any thoughts on that?

Cheers
Kevin

Ok, now I understand. Well,

Posted by shakty on August 15, 2012 at 10:03am

Ok, now I understand. Well, that is exactly why Patterns was created on the first place.

The only concern you must have is if all functionalities of your web site are covered by the current components. Check out the list on the patterns home page. We are planning to extend such a list from September on, when we will have some more dev power.

Finally, Patterns is still in beta, so I suggest to check the process of exporting/importing patterns each time you add a new functionality to the web site.

Cheers,
Stefano

Patterns

Group notifications

This group offers an RSS feed. Or subscribe to these personalized, sitewide feeds:

AltStyle によって変換されたページ (->オリジナル) /