diff --git a/lib/types.ts b/lib/types.ts index 713ebde5..da619f9b 100644 --- a/lib/types.ts +++ b/lib/types.ts @@ -143,7 +143,7 @@ export type GenerateOptions = { * Choices: `configs`, `deprecated`, `fixable` (off by default), `fixableAndHasSuggestions`, `hasSuggestions` (off by default), `options` (off by default), `requiresTypeChecking`, `type` (off by default). * Default: `['deprecated', 'configs', 'fixableAndHasSuggestions', 'requiresTypeChecking']`. */ - readonly ruleDocNotices?: readonly NOTICE_TYPE[]; + readonly ruleDocNotices?: readonly `${NOTICE_TYPE}`[]; /** Disallowed sections in each rule doc. Exit with failure if present. */ readonly ruleDocSectionExclude?: readonly string[]; /** Required sections in each rule doc. Exit with failure if missing. */ @@ -158,7 +158,7 @@ export type GenerateOptions = { * Choices: `configsError`, `configsOff`, `configsWarn`, `deprecated`, `description`, `fixable`, `fixableAndHasSuggestions` (off by default), `hasSuggestions`, `name`, `options` (off by default), `requiresTypeChecking`, `type` (off by default). * Default: `['name', 'description', 'configsError', 'configsWarn', 'configsOff', 'fixable', 'hasSuggestions', 'requiresTypeChecking', 'deprecated']`. */ - readonly ruleListColumns?: readonly COLUMN_TYPE[]; + readonly ruleListColumns?: readonly `${COLUMN_TYPE}`[]; /** * Rule property to split the rules list by. * A separate list and header will be created for each value. diff --git a/test/lib/generate/option-rule-doc-notices-test.ts b/test/lib/generate/option-rule-doc-notices-test.ts index 32e4517d..239aa105 100644 --- a/test/lib/generate/option-rule-doc-notices-test.ts +++ b/test/lib/generate/option-rule-doc-notices-test.ts @@ -174,9 +174,7 @@ describe('generate (--rule-doc-notices)', function () { it('has no issues', async function () { await expect( generate('.', { - // @ts-expect-error -- testing string value instead of enum ruleDocNotices: ['type'], - // @ts-expect-error -- testing string value instead of enum ruleListColumns: ['name'], }) ).resolves.toBeUndefined();