Including Composer Packages
Since ff uses its own class autoloader mechanism, that is incompatible with psr-4, it is also not compatible with composer's autoloader.
To include third party composer packages in your project, do like this:
In your project plugin folder create a folder named
libsand put the package'scomposer.jsonthere.After installing with
composer installit should now contain thevendorfolder.In your project plugin's
classesfolder add a fileìnclude.phpwith the following content:
<?php
require_once realpath(pathinfo(__FILE__, PATHINFO_DIRNAME) . '/../libs/vendor/autoload.php');
you can now use the package as described in their specs and
composer updateto keep it up to date.
29 März 2024