-
-
Notifications
You must be signed in to change notification settings - Fork 45
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: custom eslint parser for Vue Vine #56
Conversation
✅ Deploy Preview for vue-vine ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
@ShenQingchuan I see there are many rollup boilerplate code in our repo. Shall we refactor them to make them reuseable, or use pkgroll instead? I use it to build the create-vine-app cli in #49 |
@so1ve For sure! Any refactor that brings efficient is definitely worth it. If we can't avoid do that for 2 times due to there're 2 PRs left here right now, we could just setup them in the same way, and decrease the difference as much as possible so that there'll not be so many conflicts to resolve. If you chose to do that in one of these 2 PRs, you can go for it and rebase it in the other PR. Thanks! 💖 You're my GOAT ! |
I wonder if doing such refactor in these two PRs will cause huge merge conflict... Let's merge these two PRs anyway, thus we can refactor in |
7168b25
to
546bf05
Compare
fb4e2c0
to
4f974db
Compare
…/eslint-parser
c202914
to
dce5b2b
Compare
dce5b2b
to
72e876e
Compare
Preview videovue-vine-eslint-parser-with-desc.mp4Drawbacks nowBased on what's been tested so far, there are some standard rules that still need to be handled specifically for the Vue Vine scenario. For example, StartTag for an HTML tag that taking up multiple lines and having different attributes in rows can cause ESLint to report no-multi-spaces. Which means we may need to do the same. |
Why this?
We can't reuse vue-eslint-parser because it's made for scanning and analyzing the
.vue
SFC file, and may not satisfies our requirements that well.We must make our own custom ESTree to represent a VCF(Vine component function).
There'll be a representation of Vue's template in VCF's return statement.
Milestones
VTemplateRoot
ESTree root node.May put in another PR
eslint-plugin-vue-vine
package to maintain rules for Vue Vine.