neo4j-contrib / graphgist

Easy publishing with graph data included
http://gist.neo4j.org/
209 stars 68 forks source link

toc macro not supported #35

Open abelsromero opened 8 years ago

abelsromero commented 8 years ago

I wanted to set the table of contents at some specific point using the :toc: macro(http://asciidoctor.org/docs/user-manual/#manual-placement) option.

But when including the toc::[] macro, rendering fails with the message:

Error while parsing the AsciiDoc source - TypeError:
Cannot read property '_scope' of undefined
nawroth commented 8 years ago

I think the issue is that an old version of Asciidoctor is used. We have it working over at http://gist.asciidoctor.org/ which uses a more recent version.

abelsromero commented 8 years ago

Seems so, the last commtit on asciidoctor.js reads Upgrade to asciidoctor.js 1.5.0.preview.1..

It only requires to replace the file right?

nawroth commented 8 years ago

Asciidoctor made some changes to the syntax in later versions but we could have compat-mode enabled by default maybe. My thinking has been to do the upgrade when we do other changes to the GraphGist format anyhow.

nawroth commented 8 years ago

I did a quick try, and the queries etc didn't work. TOCs worked fine though. My guess is that the produced HTML differs a bit somewhere so the post-processing doesn't find what it's looking for.

whatSocks commented 8 years ago

I am having some minor issues with the TOC as well, but I'm not sure what is causing them. It seems to work sometimes and others not.

abelsromero commented 8 years ago

What toc options are you trying?