The Art of Adaptability in Open Source: My Experience with Yii2 and Yii3.

Nov 1, 2023General

I'm Wilmer Arambula, also known as terabytesoftw on GitHub. As a developer, my focus is on Open Source, primarily working with PHP frameworks Yii2 and Yii3.

I've contributed to over 70 repositories, with my most notable work being the migration of the Yiisoft/Db component from Yii2 to Yii3 alongside @DarkDef_PR. Over more than two years, we developed a database-agnostic package that operates with or without a di container, offering a straightforward and clean configuration. It's compatible with MSSQL, MySQL, MariaDB, PostgreSQL, Oracle, and SQLite. Technology, especially programming and its tools, is rapidly advancing. Artificial intelligence is a prime example of this evolution. To avoid obsolescence, it is crucial to constantly adapt to changes and understand that learning is an endless journey one of the great secrets of our profession. In this series of posts, i will guide you through creating a simple blog using Yii2 and Yii3.

Some may wonder if Yii2 is obsolete or just a legacy, questioning why not develop solely in Yii3. The truth is, frameworks provide the tools for any development, and it all depends on the approach and design you choose to use. Developing a blog in Yii2 with practices like Vertical Slices, Dependency Injection, and the Repository Pattern is perfectly feasible. This approach allows for code to be decoupled from the framework by defining specific interfaces. Yii2 offers a Service Locator and a DI Container that allows for the definition of classes, singletons, and their instantiation in any controller.

Moreover, its flexibility in design structure enables the customization of controllers and views, division of controllers into actions, and creation of services and events that simplify controllers and foster code reuse. In my next post, i will detail the use of Yiisoft/Config, a powerful library for managing configurations, creating your container, and automating your application management. Unveiling the art of adapting and evolving with #OpenSource. Join me in this series on creating a blog with #Yii2 and #Yii3, and learn how to keep your code up-to-date and efficient! Coming soon: The Concept of Configuration.

Happy coding!