'How to automatically apply style to all images/diagrams with asciidoctor?

I would like that all images/diagram to be centered in my document.

I know I can center them this way:

[plantuml, align="center"]
....
Some diagram
....

But I would like it to be automatic.



Solution 1:[1]

You need to apply some CSS to achieve that, assuming that your output is HTML. If your need to achieve the same for PDF, you'd need to adjust the theme that you are using.

To add some CSS for HTML, see the section on Docinfo Files.

To customize a PDF theme, refer to the theming guide.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 eskwayrd