-
Hi, I would like to call a custom javascript function in my announcement banner, because I would like to be able to adjust the content over multiple versions of the docs at the same time (main & dev branches mainly) without merging changes through all relevant branches. I'd do that by loading in some html from an external source (e.g. https://www.w3schools.com/howto/howto_html_include.asp) and directly calling the js function. Therefore my theme options would look like this {
"announcement": """
<div w3-include-html=\"https://some.location/announcement.html\"></div>
<script>
includeHTML();
</script>
"""
} However, the all the content is placed on the html before the javascript imports, so I would need to revert the order of loading the body and the scripts: furo/src/furo/theme/furo/base.html Lines 83 to 102 in 9b94420 I would make a fork and add the changes, however I thought, that this might be interesting for others as well? So it could find its way into the furo package. What do you think? Have a nice weekend! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
Somebody told me how to use javascript corretly, so no more need for this. |
Beta Was this translation helpful? Give feedback.
Somebody told me how to use javascript corretly, so no more need for this.