-
-
Notifications
You must be signed in to change notification settings - Fork 30
Add eslint-plugin-markdown for JavaScript code samples in documentation #134
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add eslint-plugin-markdown for JavaScript code samples in documentation #134
Conversation
1d67970
to
cddad8c
Compare
docs/rules/consistent-output.md
Outdated
@@ -13,51 +13,45 @@ This rule aims to ensure that if any invalid test cases have output assertions, | |||
Examples of **incorrect** code for this rule: | |||
|
|||
```js | |||
/* eslint eslint-plugin/consistent-output: error */ | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why removing the inline config?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I just added the inline configs back. I thought it seemed redundant and not all of the rule doc examples use it. But we can leave as-is for now.
.eslintrc.js
Outdated
plugins: ['markdown'], | ||
parserOptions: { | ||
sourceType: 'module', | ||
}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sourceType
should be "scripts".
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Update: I removed this config so it would default to script
.
cddad8c
to
161026d
Compare
…entation This applies our JavaScript linting to the JavaScript code samples in the markdown documentation files. * Autofixes styling/formatting/whitespace * Fixes and prevents syntax errors
161026d
to
6dcb7b5
Compare
This applies our JavaScript linting to the JavaScript code samples in the markdown documentation files. Goal is to generally improve the quality, reliability, and consistency of our documentation.