Skip to content

Commit 3ab0f34

Browse files
chore: fix linting of markdown code blocks (#286)
* fix linting of markdown code blocks * revert markdown autofix * remove duplicated extensions * Trimmed around comments --------- Co-authored-by: Josh Goldberg <[email protected]>
1 parent cf99522 commit 3ab0f34

File tree

1 file changed

+12
-3
lines changed

1 file changed

+12
-3
lines changed

.eslintrc.cjs

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,17 +13,25 @@ module.exports = {
1313
overrides: [
1414
{
1515
extends: ["plugin:markdown/recommended"],
16-
files: ["**/*.{md}"],
16+
files: ["**/*.md"],
1717
processor: "markdown/markdown",
1818
},
1919
{
2020
extends: [
2121
"plugin:@typescript-eslint/recommended",
22-
"plugin:@typescript-eslint/recommended-requiring-type-checking",
2322
"plugin:typescript-sort-keys/recommended",
23+
],
24+
files: ["**/*.ts"],
25+
parser: "@typescript-eslint/parser",
26+
},
27+
{
28+
extends: [
29+
"plugin:@typescript-eslint/recommended-requiring-type-checking",
2430
"plugin:@typescript-eslint/strict",
2531
],
26-
files: ["**/*.{ts,tsx}"],
32+
excludedFiles: ["**/*.md/*.ts"],
33+
files: ["**/*.ts"],
34+
parser: "@typescript-eslint/parser",
2735
parserOptions: {
2836
project: "./tsconfig.eslint.json",
2937
},
@@ -44,6 +52,7 @@ module.exports = {
4452
{
4553
files: "**/*.test.ts",
4654
rules: {
55+
// These on-by-default rules aren't useful in test files.
4756
"@typescript-eslint/no-unsafe-assignment": "off",
4857
"@typescript-eslint/no-unsafe-call": "off",
4958
},

0 commit comments

Comments
 (0)