Skip to content

Multiple TypeScript errors when type checking eslint.config.js examples from documentation #1068

Closed
@dschuessler

Description

@dschuessler

Before You File a Bug Report Please Confirm You Have Done The Following...

  • I have tried restarting my IDE and the issue persists.
  • I have updated to the latest version of the packages.

What version of ESLint are you using?

9.20.0

What version of eslint-plugin-svelte are you using?

2.46.1

What did you do?

The example configuration from the documentation has type errors when checked with TypeScript.

Steps to reproduce:

  1. git clone https://github.com/dschuessler/eslint-plugin-svelte-bug
  2. cd eslint-plugin-svelte-bug
  3. npm install
  4. Open folder in VSCode.
  5. Open eslint.config.js in VSCode.

What did you expect to happen?

No errors, because the file is taken from the documentation.

What actually happened?

Multiple Typescript errors:

At line 5:

Module '"/Users/dennis/Library/Caches/typescript/5.6/node_modules/@types/espree/index"' has no default export.ts(1192)

At line 7:

Cannot find name 'js'.

At line 8:

Type 'LegacyConfig<RulesRecord, RulesRecord>' must have a '[Symbol.iterator]()' method that returns an iterator.ts(2488)

Link to GitHub Repo with Minimal Reproducible Example

https://github.com/dschuessler/eslint-plugin-svelte-bug

Additional comments

Thank you for your work!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions