kramdown-rfc icon indicating copy to clipboard operation
kramdown-rfc copied to clipboard

xref in figure

Open martinthomson opened this issue 7 years ago • 2 comments

Including a {{?RFCXXXX}} reference in a figure leads to some strange results. The final document has the reference added to the right section, but the figure isn't updated to [RFCXXXX], instead it shows {{RFCXXXX}} (the "?" is removed).

Now I don't believe that references in figures need to be respected. Doing so would make it hard to include literal, unmodified text. However, this particular outcome is a little unexpected.

See the RFC5827 reference in https://raw.githubusercontent.com/quicwg/base-drafts/3dbbbf1227b359681850fddd631f389379655d73/draft-ietf-quic-recovery.md

martinthomson avatar Mar 08 '17 23:03 martinthomson

The slightly surprising behavior is an artifact of the way the YAML header autogeneration happens (by substitution before markdown parsing). Not sure that this needs to be fixed, as references in figures will continue to not work.

cabo avatar Mar 15 '17 06:03 cabo

My only suggestion would be to warn or generate an error if this happens.

martinthomson avatar Mar 16 '17 07:03 martinthomson