Closed nunocunha closed 1 year ago
I'm kind of surprised anything is happening at all with the class decorator, tbh.
The AST hasn't specified anything for the class decorator:
So that's kinda goofy.
If you have time for a few failing tests in a PR, that'd be super helpful <3
Apparently this is an issue with vanilla ESLint and TypeScript. I was trying to use "indent" for both JS and TS, but it doesn't support TS. More info here. So I ended up separating "indent" for JS only and used "@typescript-eslint/indent" for TS, as one should do. Doing this solved my issue.
Sorry I took a while to get back to you.
P.S.: Disregard that commit reference, I was trying to figure everything out, while being tired after a long day of work. It isn't an issue with this plugin.
Description
No entirely sure on how to create a reproduction example, but mixing indent with decorator-position/decorator-position makes ESLint go crazy.
.eslintrc.js
example.js
Expected (
eslint ./example.js --fix
)Actual (
eslint ./example --fix
)Notes
It seems that
decorator-position/decorator-position
is affectingindent
, as ESLint expects the line after the decorator to have one more indent level than the decorator.