danijar / handout

Turn Python scripts into handouts with Markdown and figures

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

image misplaced to end of file

epogrebnyak opened this issue · comments

I got to use handout for a simple jupyter-like visualisation and was adding an image in the middle of the file.

The image does show up, but at the end of file. This is not an intended behaviour, right?

What can be causing it? I initially thought Spyder/ipython session could be the problem,
but a standalone intepreter run does the same.

Here is my output:
https://epogrebnyak.github.io/sna-ru/handout/index.html

Here is the code:
epogrebnyak/sna-ru#1

Are you calling doc.show() after adding the image?

Indeed! Now I rememeber doc.show() pushes a queue of object sto html.

Maybe add a docstring to

def show(self):

For example:

"""Insert added items at this point in script and save to <outdir>/index.html"""