Thanks in advance :)
I can confirm the module is working correctly. I have tried adding the following to the di.xml file in my module:
<preference for="Magento\Framework\View\Page\Config\Renderer" type="Vendor\Module\Framework\View\Page\Config\Renderer" />
And the following to my Renderer.php file in app\code\Vendor\Module\Framework\View\Page\Config:
<?php
namespace Vendor\Module\Framework\View\Page\Config;
use Magento\Framework\View\Page\Config\Renderer as MagentoRenderer;
class Renderer extends MagentoRenderer
{
/**
* Render head content
*
* @return string
*/
public function renderHeadContent()
{
$result = '';
return $result;
}
}
Without any effect and no entries in any log to debug.
I can make these changes directly here:
vendor\magento\framework\View\Page\Config\Renderer.php
or here
lib\internal\Magento\Framework\View\Page\Config\Renderer.php
and the changes are then visible, but for obvious reasons would like to stay away from the core and restrict my changes to modules.
I would like to start with overriding public function renderHeadContent, but ultimately, I would like to modify protected function addDefaultAttributes. Any advice or assistance would be appreciated, thanks!
Tried: Magento 2: Overriding a protected function that implements another interface
Also tried: How to override /vendor/magento/framework/Logger/Handler/system.php
Also tried: Override framework file vendor/magento/framework/View/Element/Html/Link/Current.php