markdown-it-block-image
Plugin for markdown-it that detects and outputs block level images.
Example input:
Here is an inline image: ![example inline image](http://example.com/img/example.png). ![example block image](http://example.com/img/example.png)
Output (with default options):
Here is an inline image: .
Output (with a container element and classes):
Here is an inline image: .
Install
$ npm install --save markdown-it-block-image
Usage
var md = ;var blockImagePlugin = ; md; var input = "![example block image](http://example.com/img/example.png)";var output = md; console;
Options
Option | Type | Default | Description |
---|---|---|---|
outputContainer |
string | null |
null |
Indicates the type of container element to add; for instance, "div" . Specify null to disable output of container. |
containerClassName |
string | null |
"block-image" |
Class name for image container element. |
Contribution Agreement
This project is licensed under the MIT license (see LICENSE). To be in the best position to enforce these licenses the copyright status of this project needs to be as simple as possible. To achieve this the following terms and conditions must be met:
-
All contributed content (including but not limited to source code, text, image, videos, bug reports, suggestions, ideas, etc.) must be the contributors own work.
-
The contributor disclaims all copyright and accepts that their contributed content will be released to the public domain.
-
The act of submitting a contribution indicates that the contributor agrees with this agreement. This includes (but is not limited to) pull requests, issues, tickets, e-mails, newsgroups, blogs, forums, etc.