diff --git a/papyri/render.py b/papyri/render.py
index a9e4a23e..f1d5429b 100644
--- a/papyri/render.py
+++ b/papyri/render.py
@@ -657,7 +657,8 @@ def render_one(
backrefs_ = (None, group_backrefs(backrefs, self.LR))
- root = self._myst_root(doc)
+
+ root = json.dumps(self._myst_root(doc).to_dict(), indent=2)
try:
module = qa.split(".")[0]
return template.render(
diff --git a/papyri/templates/html.tpl.j2 b/papyri/templates/html.tpl.j2
index 4b0aae64..6302c31e 100644
--- a/papyri/templates/html.tpl.j2
+++ b/papyri/templates/html.tpl.j2
@@ -4,12 +4,12 @@
-{% from 'macros.tpl.j2' import render_paragraph, example, render_myst, render_II with context %}
+{% from 'macros.tpl.j2' import render_paragraph, example, render_myst_json, render_II with context %}
{% from 'graph.tpl.j2' import d3script with context%}
-{{render_myst(myst_root)}}
+{{render_myst_json(myst_root)}}
{% if backrefs[0] or backrefs[1] %}
diff --git a/papyri/templates/macros.tpl.j2 b/papyri/templates/macros.tpl.j2
index 5b4500cb..e1ba06b7 100644
--- a/papyri/templates/macros.tpl.j2
+++ b/papyri/templates/macros.tpl.j2
@@ -5,6 +5,15 @@
{%- endfor %}
{%- endmacro %}
+
+
+{% macro render_myst_json(json) -%}
+ {% set key = uuid() %}
+
+
+{%- endmacro %}
{% macro render_myst(obj) -%}
{% set astJson = obj.to_dict() %}
{% set key = uuid() %}