-
-
Notifications
You must be signed in to change notification settings - Fork 75
Conversation
Hi @michalsnik, thanks for this really valuable contribution! I apologise for the inconvenience but this parser just underwent a major internal refactor in which the core parsing logic was extracted and put into its own freestanding project. This doesn't impact the need nor implementation of your PR, but there are some conflicts. Hopefully they should be relatively straightforward to resolve |
I have requested review from @mysticatea as he originally suggested creating this PR and was the one who implemented the relevant custom parser API in ESLint |
Thank you @JamesHenry, sure thing! I updated my PR so it doesn't conflict with the parser anymore. |
Hi. I'm sorry for the late response. I had been away from OSS activity because of some health problem. The implementation looks good to me. However, I guess that we need more investigation because the
|
I did small downstream check then I see no problem on core rules in my some repositories at least. |
@mysticatea Thanks!
We have https://github.com/nzakas/eslint-plugin-typescript |
Looks like there are some merge conflicts now. @JamesHenry Looks like @mysticatea approved this - how do you feel about merging this once the conflicts are resolved? |
8d79499
to
c707b5d
Compare
Conflicts resolved |
This PR implements visitor keys, as described in the official ESLint documentation
Reasoning:
There is a problem while using Vue with Typescript (with eslint-plugin-vue) and some of the reported errors point to wrong locations in the file. The original issue can be found here: vuejs/vue-cli#1672
I nailed it down to a problem with
vue-eslint-parser
that didn't fix locations oftypeAnnotations
, so I posted the PR there: vuejs/vue-eslint-parser#31This however is only a
quick fix
. In order to fully fix the problem and make sure we properly traverse and fix locations of each AST node produced bytypescript-eslint-parser
insidevue-eslint-parser
we need to havevisitorKeys
setup in here and this is what I'm exactly doing in this PR.I went through the whole parser's code and tried to catch everything I could in terms of those keys, but it's possible I didn't catch it all, so I'd be grateful for feedback if there's anything I didn't consider initially.