eslint-plugin-mdx-patch
v0.1.3
Published
Enforce some rules to patch a couple of issues from the current MDX parser
Maintainers
Readme
eslint-plugin-mdx-patch
Enforce some rules to patch a couple of issues from the current MDX parser
Installation
You'll first need to install ESLint:
$ npm i eslint --save-dev
$ yarn add -D eslintNext, install eslint-plugin-mdx-patch:
$ npm install eslint-plugin-mdx-patch --save-dev
$ yarn add -D eslint-plugin-mdx-patchUsage
Add mdx-patch to the plugins section of your .eslintrc configuration file. You can omit the eslint-plugin- prefix:
overrides: [
{
files: '*.md',
plugins: ['mdx-patch'],
extends: ['plugin:mdx/recommended'],
rules: {
'mdx-patch/block-level-blank-lines': 2,
},
},
],If you use eslint-plugin-prettier, make sure to use the correct parser:
overrides: [
{
files: '*.md',
plugins: ['mdx-patch'],
extends: ['plugin:mdx/recommended'],
rules: {
'prettier/prettier': [ 'error', { parser: 'mdx' } ],
'mdx-patch/block-level-blank-lines': 2,
},
},
],