I am importing a third-party package into my project using composer.
The composer.json
of the package autoloads its classes using "classmap"
:
{
...
"name"=>"vendor/project",
...
"require": {
"php": ">=5.2.0"
},
"type": "library",
"include-path":["src/"],
"classmap": [
"src/path/to/lib1",
"src/path/to/lib2"
]
...
}
My project composer.json
pulls the package in using "require"
.
{
...
"require": {
"vendor/project": "m.n.*",
}
...
}
I'd like to add a namespace that can prefix all the classes of that package when I use it in my project, can I do this in composer?
I am aware I can use autoload at the level of my project, but presumably these classes don't need loading again and where do I point it?