I am developing test (Custom Magento Extension) module and I want to integrate third party library into my Magento 2 extension which will be using files under this library. Can anyone suggest how to integrate it into extension ? API I am trying to integrate does not follow zend naming convention.
You should do two steps to work with that library:
- Download it with your module
- Make it available to the autoloader
The best way to solve all these steps is to find your library in Packagist and add it as a dependency in your module's composer.json.
If it is not available as composer package, you have another two options:
- Declare its package as a repository and add dependency in 'required' section
- Bundle it inside your package
Also if it's not a composer package, you'll need to configure your autoloader to work with that library. Here is a documentation for that.