# MD033 - No Inline HTML

## Description

This rule disallows the use of inline HTML in Markdown documents. Using inline HTML can reduce the  
portability and compatibility of Markdown content, as some platforms may restrict or sanitize HTML.

Pure Markdown is more portable and can be safely rendered in a variety of environments.

<!-- markdownlint-disable -->
## Examples

### Valid

```markdown
# Heading

This is a paragraph with **bold** and *italic* text.

> This is a blockquote

- List item 1
- List item 2

[Link text](https://example.com)

![Image alt text](image.png)
```

### Invalid

```markdown
# Heading

This is a paragraph with <strong>bold</strong> and <em>italic</em> text.

<blockquote>This is a blockquote</blockquote>

<ul>
  <li>List item 1</li>
  <li>List item 2</li>
</ul>

<a href="https://example.com">Link text</a>

<img src="image.png" alt="Image alt text">
```

### Fixed

```markdown
# Heading

This is a paragraph with **bold** and *italic* text.

> This is a blockquote

- List item 1
- List item 2

[Link text](https://example.com)

![Image alt text](image.png)
```
<!-- markdownlint-enable -->

## Configuration

This rule has the following configuration options:

- `allowed_elements`: An array of HTML tag names that are allowed. Default is an empty array.

Example configuration:

```json
{
  "MD033": {
    "allowed_elements": ["img", "br", "div"]
  }
}
```

## Special Cases

- This rule checks for any HTML tags in the Markdown content
- It does not apply to code blocks or HTML comments
- The rule can be configured to allow specific HTML tags when necessary
- Some platforms may still sanitize allowed HTML tags

## Related Rules

- [MD031 - Fenced code blocks should be surrounded by blank lines](md031.md): Ensures proper formatting of code blocks
- [MD040 - Fenced code blocks should have a language specified](md040.md): Ensures code blocks specify a language
- [MD046 - Code block style](md046.md): Ensures consistent code block style
