When mermaid support is enabled, also inject the code snippet suggested in the ExDoc README (into the HTML <body/> rather than the <head/>). This resolves rendering issues such as the menu not being displayed properly. See, for example:
When I access that page (on desktop), the menu items on the left aren't displayed (until I press PAGES/MODULES). This happens on pages without mermaid diagrams as well.
With this PR applied, things appear to be rendered fine:
I must admit that I'm not a web dev and am not entirely sure regarding the details here. However, I figured that following the 'official' ExDoc advice seems fine if it resolves issues.
When mermaid support is enabled, also inject the code snippet suggested in the ExDoc README (into the HTML
<body/>
rather than the<head/>
). This resolves rendering issues such as the menu not being displayed properly. See, for example:https://eturnal.net/tmp/rendering-broken/
When I access that page (on desktop), the menu items on the left aren't displayed (until I press PAGES/MODULES). This happens on pages without mermaid diagrams as well.
With this PR applied, things appear to be rendered fine:
https://eturnal.net/tmp/rendering-fixed/
I must admit that I'm not a web dev and am not entirely sure regarding the details here. However, I figured that following the 'official' ExDoc advice seems fine if it resolves issues.