Closed as not planned
Closed as not planned
Description
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.
- I have searched for related issues and found none that matched my issue.
- I have read the FAQ and my problem is not listed.
Relevant Package
parser
Playground Link
No response
Repro Code
import tsParser from "@typescript-eslint/parser"
ESLint Config
No response
tsconfig
Expected Result
In typescript .ts
file

it should happen like this with no typescript error
Actual Result
I've try to import this parser in ESLint Flat config which I used .ts
file, the typescript report an error on the parser packages' types declaration.

Additional Info
We can bring a fix by simply add the "types": "./dist/index.d.ts"
to packages.json
so that the TypesScript could find the declaration file in dist
instead of trying to find it at ./index.d.ts
leading to a error while there is not a ./index.d.ts
but ./dist/index.d.ts
.

I can bring up a PR if that's OK.
Versions
package | version |
---|---|
@typescript-eslint/parser |
6.4.0 |
TypeScript |
5.1.6 |
node |
20.5.0 |