!mdseo_dupe_title -h
!mdseo_len -h
!mdseo_chk_fm -h
Check that description
is between 50 and 300 characters:
!mdseo_chk_fm description --minlen 50 --maxlen 300
Check that the front matter slug
exists:
!mdseo_chk_fm slug
Check that the front matter slug
is no longer than 45 characters:
!mdseo_chk_fm slug --maxlen 45
Check that the front matter authors
exists:
!mdseo_chk_fm authors
Ignoring Checks
You may wish to ignore checks on individual files, there are two ways to do this (1) Through a special front-matter field called mdseo-ignore
or (2) by placing the word mdseo-ignore-all
in your markdown file.
With Front Matter
To ignore a check via front matter, supply the proper value(s) in the mdseo-ignore
field in your front matter. For example, if you wanted to ignore the mdseo_dupe_title
and mdseo_image
checks in a particular markdown file, you would inject the following front matter:
---
mdseo-ignore: [dupe_title, image]
---
You can find these values by consulting the help of the appropriate cli command, for example mdseo_dupe_title -h
says:
... Ignore with front matter `mdseo-ignore:[dupe_title]`
If you want to ignore all seo rules, you can also pass all
like so:
---
mdseo-ignore: all
---
There is a generic function mdseo_chk_fm
that checks the presence, min length and max length of a front matter field. You can ignore any checks conducted by this function by passing in the appropriate fields to mdseo-ignore
. These are the fields that you can ignore:
For example, if you wanted to ingore all of these fields you could put the following in your front matter:
With The Keyword mdseo-ignore-all
Some markdown files may not have front matter, or it may not be appropriate to add front matter to a file. In this case you can place the text mdseo-ignore-all
anywhere in the file and all checks will be ignored, the most common way to add this keyword is with a markdown comment:
<-- mdseo-ignore-all -->