[英]Drupal 8 extensible module development approach
I am old Drupal developer and stopped at drupal 6 and now I am starting my studies of drupal 8 modules development. 我是Drupal的老开发人员,在drupal 6停了下来,现在我开始研究drupal 8模块的开发。
I am porting a module to drupal 8 and this module that can be extended. 我正在将一个模块移植到drupal 8和这个可以扩展的模块。 The currently approach is using hooks and works well.
目前的方法是使用钩子并且运行良好。
I want to know is hooks still the best approach or using the new OOP structure with services and dependency injection. 我想知道钩子仍然是最好的方法或使用新的OOP结构与服务和依赖注入。 ( https://www.drupal.org/docs/8/api/services-and-dependency-injection )
( https://www.drupal.org/docs/8/api/services-and-dependency-injection )
Thanks in advance, 提前致谢,
Pedro Faria 佩德罗法利亚
Drupal 8的插件API可能就是你想要的
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.