You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
<example><filename="index.html">
```html
<divclass="example">
example code here
</div>
```
</file></example>
but it seems <example> and <file> tag are not recognised as a valid html tag. marked think they are paragraph elements and add a couple of <p> around them
the compiled content is:
<p><example><filename="index.html"></p><pre><codeclass="lang-html">
<div class="example">
example code here
</div>
</code></pre><p></file></example></p>
This behave make the <example> and <file> tag fail to work
This is very inconvenient, I am creating a documentation for my project which involves displaying the element, however unfortunately is automatically added a paragraph around.
My Angular directive:
<pf-panel><pf-body><p>Exemplo de painel com corpo.</p></pf-body></pf-panel>
The results:
<p><pf-panel><pf-body><p>Exemplo de painel com corpo.</p></pf-body></pf-panel></p>
Sorry to comment on this old issue, but I cannot find what happend to this issue/feature request.
I found some Issues like #283 and the PR #833 but that was not merged.
I still have the problem, that custom html tags are not recognised by the parser. Why aren't they handled like normal html?
Any inline element will get wrapped by a <p> tag if it is not inside another block element. You can use parseInline to prevent wrapping if you only want inline blocks parsed.
It's super late to join this issue, but I'd like to share an alternative approach that utilizes directive syntax which might be suitable for your needs:
Activity
lordfriend commentedon Nov 19, 2014
Well,
when I added some lines between the custom html tag and code blocks, it seems get worked. but the code blocks failed.
brunowego commentedon Mar 10, 2016
This is very inconvenient, I am creating a documentation for my project which involves displaying the element, however unfortunately is automatically added a paragraph around.
My Angular directive:
The results:
Perhaps not the purpose of this project ...
brunowego commentedon Mar 10, 2016
@chjj if you have a little time, please take a look on this issue 👍
joshbruce commentedon Dec 25, 2017
#985
ghdoergeloh commentedon Nov 30, 2020
Sorry to comment on this old issue, but I cannot find what happend to this issue/feature request.
I found some Issues like #283 and the PR #833 but that was not merged.
I still have the problem, that custom html tags are not recognised by the parser. Why aren't they handled like normal html?
ghdoergeloh commentedon Nov 30, 2020
Okay, partially it is working:
UziTech commentedon Nov 30, 2020
That is because there is a difference between an HTML block and inline HTML.
Any inline element will get wrapped by a
<p>tag if it is not inside another block element. You can useparseInlineto prevent wrapping if you only want inline blocks parsed.bent10 commentedon Oct 26, 2023
It's super late to join this issue, but I'd like to share an alternative approach that utilizes directive syntax which might be suitable for your needs:
Yields: