Published on

2022 Wrapped

Authors

Earlier this year, we shared a roadmap for what we had in store for Leaf throughout the year. This article is to take us through what we've been able to achieve, both listed and unlisted on our roadmap.


Developer Experience

2022 was huge for us in terms of developer experience. As mentioned on our Leaf 3 launch, developer experience was going to be the main focus of all our libraries, modules and even Leaf core. We talked about tools and a syntax that developers could relate to and then getting rid of complex concepts, thereby making Leaf super easy to use for both beginners and experienced developers.

Throughout the year, we've taken this seriously. We've introduced tools and removed various complexities from our existing modules. We also played around with experimental features like a "hot-reloaoding" server and "Eien Server" which was released in October 2022. All of these are huge steps taken to drive Leaf towards the ultimate developer experience.

Efficiency

At Leaf, we define efficiency as the fastest and most performant way to get some feature implemented. Earlier this year, we took a couple of big steps towards our goal of allowing Leaf devs achieve the highest form of efficiency with Leaf. This involved introducing some breaking changes, however, the community responded possitively to the changes we introduced and we noticed improvements in some basic metrics like application speed, development time and our learning curve. We still have a ton of features and fixes planned to improve Leaf's efficiency in any use-case but we've created a good foundation for all of those changes.

PHP 8+ Support

We promised much more extensive support for PHP 8. Although we've still not been able to fully take advantage of everything PHP 8+ brings to the table, you can easily write your Leaf apps with PHP 8+ without any backlash. Currently, only the Leaf router takes advantage of the sweet tooling found in PHP 8, but we'll gradually add more support as time goes on.

Note that the support we use is in reference to Leaf's core codebase. In your apps, Leaf won't really care about which version of PHP you're using as long as it's higher than PHP 7.1.

Security

Security was another area of importance for us in 2022. We took steps to take care of most of the known security vulnerabilities which can usually be exploited in your apps. Leaf does this seamlessly without introducing any extra complexity into your applications. Gradually, we've added more features and even modules to Leaf Anchor, and we'll continue to expand our core security module.

Community

Leaf wouldn't be what is it today without our amazing community, and so one of our goals for 2022 was to engage more with our community. Just as promised, we had more interactions with our community (especially on discord). We took the time to understand our users' top features and how users tend to approach building with Leaf. This amazing experience led to us finding better ways to build features that would fit right into our users' applications.

In addition to understanding the way our users build applications with Leaf, we also had a much larger number of people from our community contributing code to Leaf and our modules. The number of contributions in 2022 was more than the numbers recorded in 2021 and 2020 put together. We also had amazing people from our community volunteer to translate our documentation into Portuguese, Spanish and French. In addition to all this, the community was much more active in fixing bugs and helping other users who were facing challenges using Leaf.

Considering the success of interacting with our community, we're going to continue engaging the Leaf community in hopes of designing and building more features together.

Learning Platforms

Since Leaf is relatively new, the only source of education for Leaf users is the maintainers. For this reason, we decided to create some learning channels for both basic and advanced users.

  • We started Codelabs earlier and even had some community users contribute their experiences, however, updating Codelabs has been more and more difficult for our only our maintainers to handle. We do promise to make more effort in that section.

  • We published a couple of videos on the Leaf YouTube Channel on topics like the Leaf CLI, testing and basic setup. These videos have been very successful. The channel has also received a ton of new subscribers and we even secured the @leafphp username, however, just as with Codelabs, it's been too much effort for solely our maintainers. We still make videos but just take a really long time to get them done.

  • Since work on the 2 channels listed above was super slow, we decided to create an interactive tutorial which allows you to run Leaf directly in your browser. This tutorial covers pretty much everything you need to build a Leaf application with advanced features from scratch. The community's adoption of this tutorial was superb and some users even put in requests for things they didn't understand.

Overall, we can do better in the content delivery section, however, we're glad to know that users have been able to take the material given on our docs and build amazing products used all around the world.

Leaf 2.7

Leaf 2.7 which is a compatability build for version 3 was scheduled to be released before the end of 2022, however, we weren't able to meet this timeline. We instead worked towards pushing Leaf 3 in a more developer friendly direction while also tackling pressing issues and improving performance as much as possible. The release of Leaf 2.7 which is currently in the workshop will be pushed back indefinitely until we've gotten Leaf 3 and important modules working the way our maintainers and community believe they should work.

Eien Server

Eien server is an experiement conducted in October 2022 that sought to bring the power of tools like Swoole into the simple and straightforward environment of Leaf applications. The experiement was largely successful as we were able to increase Leaf's performance up to 48x which is just completely insane.

Eien wasn't just created to be an insane performance boost but also serve as the foundation for async programming in Leaf as well as the introduction of systems like websockets. The first phase of Eien which was meant to add Swoole support to Leaf ended successfully, and we'll continue to build on this success.

What's next?

2022 has been a very productive year for Leaf and all of our libraries. We've pulled of a whole lot of insane stunts, integrations and collaborations with other open-sourced projects like Viewi. We've also had more financial support than the first 2 years put together and we plan to take this to another level by fully funding our maintainers to fully work on Leaf and all of our libraries. This is the main goal we wish to achieve in 2023 as this will allow our maintainers and community to grow Leaf even more than what we've seen this year.

Stats for the year

leaf3-STATS

  • 1,182 new commits
  • 436 new stars
  • 37 new issues closed
  • ~3k new views on YouTube videos
  • 72 new YouTube subscribers
  • $269 in donations
  • 7 new financial contributors
  • 24 new code contributors
  • 400 new twitter followers
  • 56 new Discord members