mirror of
https://github.com/DavidAnson/markdownlint.git
synced 2025-12-16 14:00:13 +01:00
Add .mjs to linting, switch from eslint-plugin-node (no longer maintained) to eslint-plugin-n, update suppressions.
This commit is contained in:
parent
a2b1353db5
commit
0294b9bcc8
9 changed files with 59 additions and 56 deletions
|
|
@ -17,7 +17,7 @@ const languageJavaScript = /js|javascript/i;
|
|||
function cleanJsdocRulesFromEslintConfig(config) {
|
||||
const cleanedConfig = { ...config };
|
||||
for (const rule in config.rules) {
|
||||
if (/^(es|jsdoc|node|unicorn)\//.test(rule)) {
|
||||
if (/^(es|jsdoc|n|unicorn)\//.test(rule)) {
|
||||
delete cleanedConfig.rules[rule];
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -10,8 +10,8 @@ module.exports = {
|
|||
"tags": [ "test", "validate", "json" ],
|
||||
"asynchronous": true,
|
||||
"function": async(params, onError) => {
|
||||
// eslint-disable-next-line max-len, node/no-unsupported-features/es-syntax
|
||||
const { "default": stripJsonComments } = await import("strip-json-comments");
|
||||
const { "default": stripJsonComments } =
|
||||
await import("strip-json-comments");
|
||||
filterTokens(params, "fence", (fence) => {
|
||||
if (/jsonc?/i.test(fence.info)) {
|
||||
try {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue