In November of 2009, I wrote about why developers should write their own frameworks. I pointed out at the time that often developing a framework forces developers to make the kinds of architectural choices that frameworks require, which helps them better understand the architectural choices in the most popular frameworks.
I haven’t stopped believing in the power of doing as a learning tool. But in the past few months I’ve had an opportunity to move into more of an understanding of frameworks like Zend Framework, and I’ve come to another realization:
The people who write frameworks together are very smart.
I’ve always known that a group of very committed people could be much more effective at producing a good product than I could be on my own, and for a simple reason: the collective mind usually irons out ideas that work much more quickly than a solitary developer or thinker. This isn’t always true, but for the most part, when developers take a look at something like Zend Framework, it should be obvious that the community around it came up with some very good ideas.
Having written a framework and then used an existing framework was very eye opening to me, both in terms of understanding the challenges that Zend Framework must overcome, and understanding how I resolved some of those challenges. There’s also vindication in my approach to some degree: the idea of a front controller that dispatches an action controller is something I implemented in my framework. My implementation is crude, but there none-the-less.
The point of this article is to encourage developers to experiment, but remind them that at the same time, there are already existing solutions that work exceptionally well for many if not most needs. Exploring the concept of developing a framework helped me to better understand the work I was doing; I’m still continuing work on my own framework to this day, not because I use it in production but because it’s something fun and different to work on, and because as I learn new things it’s nice to implement them. In fact, now that my server has moved over to PHP 5.3, I’ll be implementing namespaces next.
Remember that being a developer is a creative role. Remember to dream, to experiment, and then to come back down to earth and use what works best. Development is about invention. Development is about improving things. It’s about never-ending curiosity and always striving to make things better. And that’s why developers should write their own frameworks: because its what we love to do.
Be the first to get Modern Object-Oriented PHP!
Long to learn how you can develop modern applications using object-oriented PHP? Curious about how to apply all these best practices to your code?
Modern Object-Oriented PHP is a brand-new book focused on teaching you the techniques you need for writing modern, well-designed object-oriented applications!
The book lands in April. Sign up today for a sample chapter plus special launch day discounts!