-
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
54 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
"extends": "../../tsconfig.json", | ||
"compilerOptions": { | ||
"noEmit": true, | ||
"rootDir": "../..", | ||
"strict": true | ||
}, | ||
"files": ["../../dist/esm/index.d.ts", "types.test.ts"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
import json from "@eslint/json"; | ||
import { ESLint } from "eslint"; | ||
|
||
json satisfies ESLint.Plugin; | ||
json.meta.name satisfies string; | ||
json.meta.version satisfies string; | ||
|
||
// Check that these languages are defined: | ||
json.languages.json satisfies object; | ||
json.languages.json5 satisfies object; | ||
json.languages.jsonc satisfies object; | ||
|
||
// Check that `plugins` in the recommended config is defined: | ||
json.configs.recommended.plugins satisfies object; | ||
|
||
{ | ||
type RecommendedRuleName = keyof typeof json.configs.recommended.rules; | ||
type RuleName = `json/${keyof typeof json.rules}`; | ||
type AssertAllNamesIn<T1 extends T2, T2> = never; | ||
|
||
// Check that all recommended rule names match the names of existing rules in this plugin. | ||
null as AssertAllNamesIn<RecommendedRuleName, RuleName>; | ||
} |