Open dingo-d opened 3 years ago
PHP-Scoper may be a superior namespace changer. https://github.com/humbug/php-scoper/issues/303
For scoper I think I'd need to use https://github.com/bamarni/composer-bin-plugin plugin, plus they say that:
Keep in mind however that this library is not designed to be extended.
Which is a bit worrying :S
bin-plugin
is really called PHIVE.
phive update humbug/php-scoper --force-accept-unsigned
There is a GitHub Action for PHIVE.
PHP-Scoper may be a superior namespace changer.
Agree.
In my project, I'm using the imposter plugin to avoid any conflicts in my project in case I have a plugin that is using different versions of some packages that my project is using.
But for some reason, it only covers these packages and files
It picks up the dependencies correctly, but from the
wp-queue
, only thefunctions.php
namespace gets changed. In other classes it remains the same, so now thefunctions.php
file looks likeAnd I get the errors because the
Queue.php
still has the namespacenamespace WP_Queue;
and notMyProjectVendor\WP_Queue\Queue
.Any ideas why? It should pick up the namespaces from the autoload directive in the
composer.json
🤷🏼♂️Love the library btw! Works like a charm locally, can't wait to test it out on our staging site 🙂