# How to add a custom footer to my Documenter-generated pages?

**URL:** https://discourse.julialang.org/t/how-to-add-a-custom-footer-to-my-documenter-generated-pages/79044
**Category:** General Usage
**Tags:** documenter
**Created:** [April 5, 2022, 12:54pm UTC](https://discourse.julialang.org/t/how-to-add-a-custom-footer-to-my-documenter-generated-pages/79044 "2022-04-05T12:54:23Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![sylvaticus](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/sylvaticus/32/203883_2.png) [@sylvaticus](https://discourse.julialang.org/u/sylvaticus)
#### Post date: [April 5, 2022, 12:54pm UTC](https://discourse.julialang.org/t/how-to-add-a-custom-footer-to-my-documenter-generated-pages/79044/1 "2022-04-05T12:54:23Z")

</div>

Hello, I need to add a ````@raw HTML` block at the end of each of my .md pages to embed [a script that uses GitHub issues as page comments](https://utteranc.es).

I could add it manually to every page, but it is not elegant, and I don’t want the actual content to be boated with these “site side” issues.

Is there a way I can hack in the `makeDoc` call to add the footer on the fly ?  
Some of my pages are coming from `*.jl` files from `Literate.jl`, but others are original `*.md` pages, and in that case, if I add indeed the footer in the `*.md` pages, like in the `MakeList` function, then I would change the original source files!

---

<div class="post-metadata">

### Author: ![sylvaticus](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/sylvaticus/32/203883_2.png) [@sylvaticus](https://discourse.julialang.org/u/sylvaticus)
#### Post date: [April 5, 2022, 1:23pm UTC](https://discourse.julialang.org/t/how-to-add-a-custom-footer-to-my-documenter-generated-pages/79044/2 "2022-04-05T13:23:59Z")

</div>

I have tried to use the keyword `footer` on the `HTML()` call, but, aside that even if it would work, it would put the comments too down to the page, but that parameter wants a single markdown line, while I need to pass it a `@raw HTML` **lock**.

Is there no way to specify a footer _within the page content area_ ?

---

<div class="post-metadata">

### Author: ![sylvaticus](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/sylvaticus/32/203883_2.png) [@sylvaticus](https://discourse.julialang.org/u/sylvaticus)
#### Post date: [April 7, 2022, 8:15pm UTC](https://discourse.julialang.org/t/how-to-add-a-custom-footer-to-my-documenter-generated-pages/79044/3 "2022-04-07T20:15:59Z")

</div>

Alternatively, isn’t possible to pass to documenter the markdown inputs of `pages` as a string or a IOBuffer instead of a file? In this way I could do the modifications before passing makedocs without touching the original files.  
Also, this could simplify the interaction with tools like Literate.jl, as we could pipe its output to makadoc onstead of passing trough a temporary `.md` file…

---

<div class="post-metadata">

### Author: ![sylvaticus](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/sylvaticus/32/203883_2.png) [@sylvaticus](https://discourse.julialang.org/u/sylvaticus)
#### Post date: [April 7, 2022, 8:29pm UTC](https://discourse.julialang.org/t/how-to-add-a-custom-footer-to-my-documenter-generated-pages/79044/4 "2022-04-07T20:29:06Z")

</div>

Or maybe simply to implement, makecall could have a customisable callback with filename, filecontent (and perhaps position in the sidebar), so we could employ our own functions…

---

<div class="post-metadata">

### Author: ![mortenpi](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/mortenpi/32/158_2.png) [@mortenpi](https://discourse.julialang.org/u/mortenpi)
#### Post date: [April 10, 2022, 10:45pm UTC](https://discourse.julialang.org/t/how-to-add-a-custom-footer-to-my-documenter-generated-pages/79044/5 "2022-04-10T22:45:30Z")

</div>

I am not sure you would want to pass this via the `footer` keyword. The page style doesn’t really expect a large complex object in that part of the page, so it may break.

I would suggest just adding at-raw blocks at the end of each `.md` file. If you don’t want to do it manually, you could run a Literate-like preprocessing to add them.

That said, if you are interested in doing pre-processing on the AST level, I do have an ancient branch to try to support different parsers, which you can take a look at. But basically the idea is that you need to provide something that returns the Markdown AST to Documenter, and so this could also be used for preprocessing: [https://github.com/JuliaDocs/Documenter.jl/issues/1074#issuecomment-515477974](https://github.com/JuliaDocs/Documenter.jl/issues/1074#issuecomment-515477974)
