posthtml-extend
posthtml-extend copied to clipboard
<blocks> in <title> of template cannot be found
When I attempt to use the example base.html
and index.html
from the README with parcel, the <block>
in the <title>
of base.html cannot be found.
If I add "strict": false
to the config the <block name="content">
gets replaced, but not the <block name="title">
Reproducing repo here: https://github.com/jessehattabaugh/posthtml-extend-bug
Adding onto this issue, the cause seems to be because title element's content is always recognized as a string in htmlparser2
so therefore it will never find the block tag as it doesn't exist. The example should be removed from the docs, as this seems to be intentional functionality.
related https://github.com/fb55/htmlparser2/issues/642