If we’re going to have this thread then lets try to do it without bashing please. There is a kernel of discussion to be had here - namely what constitutes an app, a library, a package, a component, a framework, and where do the lines get blurry. My opinion.
A component is a tight group of related classes tasked with accomplishing a single task. Ideally components should be independent and share a namespace - that is the classes within a component don’t need to make use statements to address each other. A task too small for a component is likely going to fall to a single class.
Symfony’s HttpFoundation is a good example - providing a basic I/O framework. It’s not just used by Symfony, but also by Drupal 8, Laravel and Silex (that I know of).
Packages are groups of related components. Twig is one example, Symfony in general refers to these as “Bundles”. Unlike a component which is usually a more or less drop it in decision, Packages tend to have more far reaching effects on the application since taking advantage of them will require some forethought and outside code will need to be aware of their API.
The smallest frameworks and the largest packages is a very blurry line - but frameworks style themselves to be more complete solutions than packages tend to be.
Frameworks provide a road map to solving a particular type of problem. There are general purpose frameworks - Symfony. Frameworks devoted to small scale websites - Silex, and everywhere in between. What makes Frameworks distinct from packages is they:
- Have a distinct over arching paradigm, either Model-View-Controller or Model-View-Presenter
- Have components and packages to implement the
areas of that paradigm.
- Have a configuration methodology set up in non-PHP files, usually one of XML, INI or YAML.
The largest frameworks are almost indistinguishable from apps and are ready to go from install, but the distinguishing line here is whether a non-programmer can be expected to set the code up and get it running. If not then, no matter how large and featured it is, it’s still a framework, not an app.
As a rule of thumb, the more a framework can do the harder it is to customize it. This isn’t always true though, and it also depends on what area of the app is being customized. The best frameworks tolerate having their components and packages switched out though the incoming packages will usually need a wrapper of some sort especially if the interface in that area hasn’t been standardized.
At the top, apps. If a non-programmer can be expected to install and configure the app without touching a single line of code then it’s an App. Drupal 8 is one example, and a rather huge one at that. Apps may or may not have further customization possible though the most popular ones are. The smaller apps out there can be smaller than some frameworks.
The distinctive feature of an app is installer code that creates the database, writes the config file and overall automates the setup process for a non-programmer user. Frameworks don’t have these though they might have tools for handling some parts of the install process, like creating blank model classes, route files or the like.
Increasingly in the PHP world the leading applications bring together components and packages from various vendors. The only major PHP project that doesn’t anymore is WordPress which can get away with this largely due to its marketshare - even then I’ve seen Wordpress plugins make use of component libraries. Given time even Wordpress will probably evolve over, though it’s going to have to get rid of its horrid “The Loop” to do so.