I have a workflow that checks for ESLint errors by running yarn lint
command. For this line of code:
type STEPSTYPE = { [key in Stepper]: number } | { [key in CaseStepper]: number };
I get an error:
Error: 52:86 error 'key' is defined but never used @typescript-eslint/no-unused-vars
But if I run yarn lint
locally on my computer I don’t get any errors. It runs without any errors:
yarn run v1.22.19
$ eslint ./src/**/*.{js,ts,tsx} package.json --quiet
✨ Done in 3.76s.
Why do I get 2 different outputs locally and in GitHub? How can I fix this?
3