In the previous post, I covered a few points as to why I think that include_once, require_once, and other similar statements result in poor development practices (at least when it comes to the work we’re doing with our WordPress projects).
If you haven’t read it, no big deal. The gist of the post is that these statements make:
- debugging more difficult,
- tracing code harder to do.
Ultimately, they are things we can avoid. I ended the post with the following:
This still leaves the question of why autoloading (or any inclusion of third-party files) is needed at all.
And though I’d love to cover all the details in this post, it’s going to take this and one more post as its important to understand some foundational topics on languages, interpreters, and compilers before getting too far ahead.
Continue reading