In Magento 2, is it possible to add an arbitrary bit of HTML to every frontend/cart page's <head/>
?
I know I can add a block to the content/<body>
area with code something like this
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
<body>
<referenceBlock name="content">
<block type="Pulsestorm\Test\Block\Head" name="pulsestorm.head" as="pulsestorm.head" template="pulsestorm/head.phtml"/>
</referenceBlock>
</body>
</page>
However, it's not clear if there's a similar block for adding content to the <head/>
element of a page. I've looked through the dev docs site and the source code, and there's lots of references to new tags you can use with a <head/>
tag
<head>
<css.../>
<js.../>
</head>
but I can't find any reference of a way to add arbitrary html/text to the <head/>
section of a page in Magento 2.