Skip to content

Commit

Permalink
Add TypeScript types (#2382)
Browse files Browse the repository at this point in the history
  • Loading branch information
hyoban authored Jun 23, 2024
1 parent 8d28b6e commit 68e0f13
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
12 changes: 12 additions & 0 deletions index.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
import type {ESLint, Linter} from 'eslint';

declare const eslintPluginUnicorn: ESLint.Plugin & {
configs: {
recommended: Linter.Config;
all: Linter.Config;
'flat/all': Linter.FlatConfig;
'flat/recommended': Linter.FlatConfig;
};
};

export = eslintPluginUnicorn;
2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
"url": "https://sindresorhus.com"
},
"main": "index.js",
"types": "index.d.ts",
"sideEffects": false,
"engines": {
"node": ">=18.18"
Expand All @@ -35,6 +36,7 @@
},
"files": [
"index.js",
"index.d.ts",
"rules",
"configs"
],
Expand Down

0 comments on commit 68e0f13

Please sign in to comment.