antora

How can I include and render a html file with tags in Antora?


Is there a way to include my own HTML in an Antora adoc file?

.index.adoc

include::example$test.html[]

[,html]
----
include::example$test.html[]
----

.test.html

<h1>My First Heading</h1>
<p>My first paragraph.</p>

At the moment my test.html file gets imported but the html tags are not recognized.

enter image description here


Solution

  • You have to use the following lines of code within the adoc file.

    ++++
    include::example$test.html[]
    ++++