(heavily modified the question for simplicity and clarity)
As a test case I created
<custom-theme>/Magento_Theme/layout/default_head_blocks.xml. Creating and modifying this file, according to the docs, should effect every page.
In my extended
default_head_blocks.xml I added a bogus JS, just to see what pages it will be added to.
<?xml version="1.0"?> <page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd"> <head> <script src="js/test-file.js"/> </head> </page>
I can see
test-file.js on category and CMS pages, but not on a product page.
In fact, I can't get any layout updates to have an effect on the product page. The product page has the inherited theme
Magento Blank, plus my site logo, located in
Any guidance on this issue would be appreciated.