# mdbook-image-size A mdbook preprocessor which support image size syntax ## size ### width & height From ```md ![the alt](path/to/your/image "the title" =500x400) ``` To ```html
``` ### width only From ```md ![the alt](path/to/your/image "the title" =500x) ``` To ```html ``` ### height only From ```md ![the alt](path/to/your/image "the title" =x400) ``` To ```html ``` > [!TIP] > No alt or title is ok. ## align ### left left is default ### center From ```md ![the alt](path/to/your/image "the title" =500x400 center) ``` To ```html ``` ### right From ```md ![the alt](path/to/your/image "the title" =500x400 right) ``` To ```html ``` ## Installation ```sh cargo install mdbook-image-size ``` add it as a preprocessor in book.toml ```toml [preprocessor.image-size] command = "mdbook-image-size" ```