In Symfony4 projects, I'd like to autoload classes defined in the src
folder but whose namespace does not start with App
. Let's say it starts with Acme
instead.
I was expecting that the following configuration in composer.json
to work, but it doesn't and I'm getting class not found exceptions:
"autoload": {
"psr-4": {
"App\\": "src/",
"Acme\\": "src/"
}
},
What am I missing here?