How to extend a third party extension?

I’m trying to edit a function from a third party extension, in this case, the moloni one. I want to override a function that is in Vendor\moloni\magento2\libraries\MoloniLibrary\Controllers\Products.php Until now I have a folder in app\code with app\code\Vendor\Moloni\registration.php <?php \Magento\Framework\Component\ComponentRegistrar::register( \Magento\Framework\Component\ComponentRegistrar::MODULE, ‘Vendor_Moloni’, __DIR__ ); app\code\Vendor\Moloni\etc\di.xml <?xml version=”1.0″?> <config xmlns:xsi=”http://www.w3.org/2001/XMLSchema-instance” xsi:noNamespaceSchemaLocation=”urn:magento:framework:ObjectManager/etc/config.xsd”> <preference for=”moloni\magento2\Libraries\MoloniLibrary\Controllers\Products” type=”Vendor\Moloni\Libraries\MoloniLibrary\Products” /> </config> app\code\Vendor\Moloni\etc\module.xml…

I need to remove all parts using objectManager In my Magento 2.2.3 project

Because of lack of knowledge, I currently have many parts using objectManager in my project.But I’m not sure whether I should create a module and create many functions for these various parts running by objectManager. For example, in app/design/frontend/CustomTheme/default/Magento_Catalog/templates/product/list.phtml, I’m using 4 different results just using objectManager. $_product = $objectManager->create(‘Magento\Catalog\Model\Product’)->load($_item->getId()); $storeManager = $objectManager->get(‘\Magento\Store\Model\StoreManagerInterface’); $cartlist =…

Where can I find official documentation of the internal functions and methods used by Magento’s default/core modules?

Am I missing something or does Magento not provide any documentation about the core/default modules it uses? Let’s use an example: say I want to create a module which incorporates various core functions of Magento including: Presenting a log in or registration form to the customer allowing them to log in After logging in, displaying…