Closed akosma closed 4 years ago
Yes, I think we could use the Accept
header:
Accept: text/plain
Or use the output format in the URL:
GET /plantuml/txt/SyfFKj2rKt3CoKnELR1Io4ZDoSa70000
What do you think?
Just the output format in the URL would be enough I think, and the other would be a nice bonus! Thanks
PlantUML offers two text format:
txt
(also called atxt): plain text using ascii onlyutxt
: plain text using unicode$ http :8000/plantuml/utxt/eNrjciguSSwqKc3N4XLKT1LQtVNwzMlMTlWwUshIzcnJ53JIzUsBSQIABnMM1A==
HTTP/1.1 200 OK
cache-control: public, max-age=432000
content-length: 372
content-type: text/plain; charset=utf-8
date: 1576243016424
etag: 6p09ACFG7EfRkAXkCLWl8lk0m00
expires: 1576675016424
last-modified: 1567581178724
┌───┐ ┌─────┐
│Bob│ │Alice│
└─┬─┘ └──┬──┘
│ hello │
│──────────────>│
┌─┴─┐ ┌──┴──┐
│Bob│ │Alice│
└───┘ └─────┘
$ http :8000/plantuml/txt/eNrjciguSSwqKc3N4XLKT1LQtVNwzMlMTlWwUshIzcnJ53JIzUsBSQIABnMM1A==
HTTP/1.1 200 OK
cache-control: public, max-age=432000
content-length: 224
content-type: text/plain
date: 1576243005713
etag: 6p09ACFG7EfRkAXkCLWl8lk0m00
expires: 1576675005713
last-modified: 1567581178724
,---. ,-----.
|Bob| |Alice|
`-+-' `--+--'
| hello |
|-------------->|
,-+-. ,--+--.
|Bob| |Alice|
`---' `-----'
I think in this case the Asciidoctor Kroki extension should use a literal block right?
Yes, absolutely! This is wonderful, thanks!
Thanks!
PlantUML offers the option to generate ASCII art diagrams, passing the
-txt
parameter in the command line. Would it be possible to do the same in Kroki? For example it is a useful option to embed diagrams inman
page output generated by Asciidoctor.