-
Notifications
You must be signed in to change notification settings - Fork 40
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
Fails on dynamic import #72
Comments
That is interesting, I am currently using splitchunks on some projects, which is not causing this error for me. Can you lead me to a (very small) repo that reproduces this? Maybe some more information about your configuration? Did you make some changes that got things working? Any info you have will help, I'd love to get you up and running here! |
I will try to make a minimal reproduction as well, but here is one repo that I have had this trouble on: I will make a branch that attempts to implement es6-plato (I scrapped my earlier attempt at it). Is there a difference between splitchunks and webpack's |
Well if by The unless you mean the might hit up the author of https://github.com/typhonjs-node-escomplex/typhonjs-escomplex the underlying module I am parsing with |
Yes -- I was using the dynamic |
@seanohue some time ago when I migrated this project to ES6 that was one of the better parsers (for complexity analysis) there was. If there's a better one, point me to it for sure. |
I see the issue and the latest version of the underlying parser will fix this: |
@seanohue Just popping in to say that I'm going to be implementing a fix related to project dependencies. I'll be removing Grunt as much as I can, updating globby and also updating the underplaying parser. This, among some other issues, will go away. I'll post in here when that is done and also THANK YOU for opening this issue and discussing it over this time. |
Amazing! Thanks for doing some research on this. Ping me if you need any more info. |
@seanohue ok I am still working on this. all I can say is that I can repro it. I get |
Hello,
When using this to analyze source code for a Vue project, it fails on coming across a Webpack dynamic import.
With tools like ESLint, this is solvable by using babel-eslint as a parser.
Even though I have my ESLint config with babel-eslint plugged into Plato, I still get an
Unexpected token
error.This may be solvable by using the parser described by the ESLint options or potentially offering another way to provide one's own parser. Either that, or I am configuring it wrong.
It looks like the work done in #5 may support this, rather than using typhonjs for parsing which fails to parse dynamic imports.
The text was updated successfully, but these errors were encountered: