paradox icon indicating copy to clipboard operation
paradox copied to clipboard

Add Support for numerical prefixed `id` in Snippets

Open jlprat opened this issue 8 years ago • 4 comments

Currently, it is not possible to include a Snippet whose id starts with a number. For example: @@snip [Fooscala](path/to/Foo.scala) { #0id } won't include the code surrounded by //#0id

jlprat avatar Dec 11 '16 14:12 jlprat

If I understand correctly Paradox silently ignores the snip identifier. I believe this is somewhat related with #23 in the sense that invalid identifiers do not result in an error.

jonas avatar Dec 11 '16 18:12 jonas

I think it's pretty close to #23, I'll take a closer look at the logs if it behaves the same way, I'm not on my PC now. But generally speaking, if an id starting with a number is illegal, I would expect it to fail, yes.

jlprat avatar Dec 11 '16 18:12 jlprat

I checked the behavior and it fails silently, giving the impression that the page generation worked fine. Looks like when the id starts with a number, the whole existence of the marker is not checked.

jlprat avatar Dec 11 '16 20:12 jlprat

Would be good to fix, this silently broke akka http documentation.

cc @dwijnand @eed3si9n

ktoso avatar Dec 13 '16 12:12 ktoso