posthtml-modules icon indicating copy to clipboard operation
posthtml-modules copied to clipboard

Nested module tag within content not processed

Open ghost opened this issue 4 years ago • 4 comments

"posthtml": "^0.15.2"
"posthtml-modules": "^0.7.4"

Hi,

I don't know if this is a bug or if I misinterpreted the recursion behaviour, but if I place a module tag within the html supplied for the content of another module, the "sub" module does not get processed and the content source is left unchanged. I.e. the module tag is output "as is".

Is this meant to process nested modules, or is this just not supported?

Regards, Rob.

ghost avatar Jun 05 '21 14:06 ghost

@jazael0 Hi

I don't know if this is a bug or if I misinterpreted the recursion behaviour, but if I place a module tag within the html supplied for the content of another module, the "sub" module does not get processed and the content source is left unchanged. I.e. the module tag is output "as is".

I don't really understand the question, maybe an example will give me a little more insight?

Scrum avatar Jun 11 '21 07:06 Scrum

I think I've run into this problem as well. Here's a code example:

<module src="path/to/module-a.html">
  <module src="path/to/module-b.html">content</module>
</module>

compiles to this:

<div class="a">
  <module src="path/to/module-b.html">content</module>
</div>

rather than this:

<div class="a">
  <div class="b">content</div>
</div>

sakekasi avatar Dec 02 '21 18:12 sakekasi

I'm also interested in this functionality. Is any progress on the issue?

kbychkov avatar Jun 27 '22 10:06 kbychkov

Any update on this?

thewebartisan7 avatar Sep 19 '22 07:09 thewebartisan7