Skip to content

Commit

Permalink
feat: add settings for flat config (#166)
Browse files Browse the repository at this point in the history
  • Loading branch information
sxzz committed Jan 10, 2023
1 parent bc27eb9 commit 3d63df6
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/flat-config/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,13 @@ export interface FlatESLintConfigItem {
* @see [Configuring rules](https://eslint.org/docs/latest/user-guide/configuring/configuration-files-new#configuring-rules)
*/
rules?: Rules;

/**
* An object containing name-value pairs of information that should be available to all rules.
*
* @see [Configuring shared settings](https://eslint.org/docs/latest/user-guide/configuring/configuration-files-new#configuring-shared-settings)
*/
settings?: Record<string, any>;
}

/**
Expand Down
1 change: 1 addition & 0 deletions tests/define.test-d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ describe('define', () => {
ignores: [],
plugins: {},
rules: {},
settings: {},
},
]),
).toEqualTypeOf<FlatESLintConfig[]>();
Expand Down

0 comments on commit 3d63df6

Please sign in to comment.