Skip to content

Commit

Permalink
fix(experimental-utils): add literal types to global option
Browse files Browse the repository at this point in the history
  • Loading branch information
dora1998 committed Aug 2, 2021
1 parent f0861e0 commit f36944a
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/experimental-utils/src/ts-eslint/Linter.ts
Expand Up @@ -119,6 +119,8 @@ namespace Linter {
export type RuleEntry = RuleLevel | RuleLevelAndOptions;
export type RulesRecord = Partial<Record<string, RuleEntry>>;

export type GlobalVariableOption = 'readonly' | 'writable' | 'off' | boolean;

// https://github.com/eslint/eslint/blob/v6.8.0/conf/config-schema.js
interface BaseConfig {
$schema?: string;
Expand All @@ -133,7 +135,7 @@ namespace Linter {
/**
* The global variable settings.
*/
globals?: { [name: string]: boolean };
globals?: { [name: string]: GlobalVariableOption };
/**
* The flag that disables directive comments.
*/
Expand Down

0 comments on commit f36944a

Please sign in to comment.