mirror of
https://github.com/DavidAnson/markdownlint.git
synced 2025-12-23 01:10:13 +01:00
20 lines
374 B
Markdown
20 lines
374 B
Markdown
|
|
# MD040 - Fenced code blocks should have a language specified
|
||
|
|
|
||
|
|
Tags: code, language
|
||
|
|
|
||
|
|
Aliases: fenced-code-language
|
||
|
|
|
||
|
|
This rule is triggered when fenced code blocks are used, but a language isn't
|
||
|
|
specified:
|
||
|
|
|
||
|
|
```
|
||
|
|
#!/bin/bash
|
||
|
|
echo Hello world
|
||
|
|
```
|
||
|
|
|
||
|
|
To fix this, add a language specifier to the code block:
|
||
|
|
|
||
|
|
```bash
|
||
|
|
#!/bin/bash
|
||
|
|
echo Hello world
|
||
|
|
```
|