Design Patterns and PHP 8 in Drupal Core - From Procedural to Object-Oriented Programming
Offered By: Drupal Association via YouTube
Course Description
Overview
Explore design patterns and PHP 8 features in Drupal Core through this 46-minute conference talk from the Drupal Association. Dive into the evolution of Drupal's architecture, from procedural programming to object-oriented design, and learn how it has embraced industry standards and collaboration with other frameworks. Gain insights into key concepts like Dependency Injection, Service Containers, Factory Methods, and PHP traits. Discover how Drupal 10's adoption of PHP 8.1 impacts development practices, including JIT compilation and stricter type checking. Through real-world examples and benchmarks, understand the performance improvements and code robustness achieved with PHP 8. Ideal for developers familiar with custom module and theme development, this talk provides a comprehensive understanding of standard programming patterns in Drupal core and the exciting new PHP 8 features implemented within it.
Syllabus
Intro
Procedural programming
Extended using hooks
Challenges with Drupal 7
Object oriented programming
Scenario - Car Manufacturing
Dependency Injection - Scenario
Dependency Injection - implementation
Real world is complicated!
Dependency Injection - Drupal
Enter Electric Batteries!
Electric Battery (engine?)
Adapter pattern - Drupal
Observer Pattern - Drupal
Design Patterns - benefits
Named Arguments
Deprecated Dynamic Properties
[In Discussion] Using Weakmap for container serialization solution
Attributes in place of Annotations
Use appropriate type hints wherever possible
What does this mean for the community?
Taught by
Drupal Association
Related Courses
AngularJS: Framework FundamentalsMicrosoft via edX Архитектура Android-приложений
Moscow Institute of Physics and Technology via Coursera Client-based Web Applications development: ReactJS & Angular
Universidad Politécnica de Madrid via Miríadax Getting Started with Blazor Server
Coursera Project Network via Coursera Getting Started with Blazor WASM
Coursera Project Network via Coursera