when i run mvn clean package -Pproduction -DskipTests command as usual ..
npm install gives this error.
ERROR in ../node_modules/apexcharts/dist/apexcharts.esm.js?babel-target=es5
Module build failed (from ../node_modules/babel-loader/lib/index.js):
TypeError: C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\apexcharts\dist\apexcharts.esm.js: Property left of ForInStatement expected node to be of a type ["VariableDeclaration","LVal"] but instead got null
at Object.validate (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\types\lib\definitions\utils.js:131:11)
at validateField (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\types\lib\validators\validate.js:24:9)
at Object.validate (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\types\lib\validators\validate.js:17:3)
at NodePath._replaceWith (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\path\replacement.js:172:7)
at NodePath._remove (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\path\removal.js:55:10)
at NodePath.remove (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\path\removal.js:34:8)
at hooks (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\path\lib\removal-hooks.js:11:12)
at NodePath._callRemovalHooks (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\path\removal.js:46:9)
at NodePath.remove (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\path\removal.js:26:12)
at convertFunctionParams (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\plugin-transform-parameters\lib\params.js:88:30)
at PluginPass.Function (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\plugin-transform-parameters\lib\index.js:30:53)
at newFn (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\visitors.js:179:21)
at NodePath._call (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\path\context.js:55:20)
at NodePath.call (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\path\context.js:42:17)
at NodePath.visit (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\path\context.js:90:31)
at TraversalContext.visitQueue (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\context.js:112:16)
at TraversalContext.visitSingle (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\context.js:84:19)
at TraversalContext.visit (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\context.js:140:19)
at Function.traverse.node (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\index.js:84:17)
at NodePath.visit (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\path\context.js:97:18)
at TraversalContext.visitQueue (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\context.js:112:16)
at TraversalContext.visitMultiple (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\context.js:79:17)
at TraversalContext.visit (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\context.js:138:19)
at Function.traverse.node (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\index.js:84:17)
at NodePath.visit (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\path\context.js:97:18)
at TraversalContext.visitQueue (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\context.js:112:16)
at TraversalContext.visitMultiple (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\context.js:79:17)
at TraversalContext.visit (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\context.js:138:19)
at Function.traverse.node (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\index.js:84:17)
at NodePath.visit (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\path\context.js:97:18)
at TraversalContext.visitQueue (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\context.js:112:16)
at TraversalContext.visitMultiple (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\context.js:79:17)
at TraversalContext.visit (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\context.js:138:19)
at Function.traverse.node (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\index.js:84:17)
at NodePath.visit (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\path\context.js:97:18)
at TraversalContext.visitQueue (C:\Users\UmitKIRTIL\IdeaProjects\yoksismezunaktarimiv2\node_modules\@babel\traverse\lib\context.js:112:16)
@ ../node_modules/@vaadin/flow-frontend/com/github/appreciated/apexcharts/apexcharts-wrapper.js?babel-target=es5 22:0-36 42:32-42
@ ../target/frontend/generated-flow-imports.js?babel-target=es5
Any ideas ?
Same stuff for me also. Any Help please?
Are you using apexcharts-flow?
If yes, I suggest opening an issue there too.
+1, having same issue.
Are you using apexcharts-flow?
If yes, I suggest opening an issue there too.
samerdiab already did i guess...
unfortunately it relates to js library. es6 -> es5 downgrade stuff.
Getting the same error, in a react app. I think there is something related to babel minify.
The issue is coming from svg.js as apexcharts is using an older version of [email protected]
I am tracking the cause of the issue and if possible, will try to patch the existing svg.js version.
I have updated the babel versions and made the fixes for Property left of ForInStatement expected node to be of a type ["VariableDeclaration","LVal"].
Released a new patch [email protected]. Please upgrade and update this thread if it fixed the issue.
I'm afraid it's the same issue for me after upgrade to 3.16.1
with @babel/core: 7.8.7
I have no experience with Vaadin, so not sure what's causing this.
After I upgraded to @babel/[email protected], I got the same error. Hence, I fixed those hoping that would also fix it for Vaadin.
What I did was - I put a console.log(node, key, val) on line 131 in node_modules\@babel\types\lib\definitions\utils.js:131:11 and that listed all the issues with the ForInStatement validations while building.
If anyone can provide more information after trying what I did, it will be helpful to get to the root of the issue.
So, having seen this reply in apexcharts-flow repo
https://github.com/appreciated/apexcharts-flow/issues/47#issuecomment-595312341
I went and installed yaml as a dev dependency and now it builds. Not sure why...
I have updated the babel versions and made the fixes for
Property left of ForInStatement expected node to be of a type ["VariableDeclaration","LVal"].Released a new patch [email protected]. Please upgrade and update this thread if it fixed the issue.
Thanks! Upgrading to [email protected] fixed the issue.
So, having seen this reply in apexcharts-flow repo
appreciated/apexcharts-flow#47 (comment)
I went and installed yaml as a dev dependency and now it builds. Not sure why...
I've now uninstalled yaml and it's still building, may have been something cached somewhere despite me deleting node_modules and dist etc.
Most helpful comment
Thanks! Upgrading to [email protected] fixed the issue.