Skip to content

Add type support to the created eslintrc #5635

Open
@NotWearingPants

Description

@NotWearingPants

What problem does this feature solve?

It adds autocompletion in eslintrc and allows type-checking it.

What does the proposed API look like?

This can be done by installing @types/eslint and then adding the following type declaration to the top of the generated .eslintrc.js file:

/**
 * @type {import('eslint').Linter.Config<import('eslint/rules/index').ESLintRules>}
 */

This might be possible to instead do in a separate .d.ts file, but I'm not very proficient in typescript yet.

I'm not sure how to configure the type-checking to actually run on .eslintrc.js.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions