TypeError: traverse is not a function #13093
-
My code snippet -
I am continuously getting:
Can anyone help me out. I have used the package @babel/traverse as required to use the functionality but I don't find why isn't this working. Any help would be great. Thanks |
Beta Was this translation helpful? Give feedback.
Answered by
nicolo-ribaudo
Apr 2, 2021
Replies: 2 comments 4 replies
-
You are using |
Beta Was this translation helpful? Give feedback.
1 reply
-
If you are using native ESM, you need to use |
Beta Was this translation helpful? Give feedback.
3 replies
Answer selected by
khushal87
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
If you are using native ESM, you need to use
traverse.default
instead oftraverse
(that's how Node.js' interop between ESM and CJS works).