How to solve SyntaxError: Cannot use import statement outside a module
isssuse
#93
Answered
by
ChristianMurphy
Sachin-chaurasiya
asked this question in
Q&A
-
I am using this package with react-markdown as
|
Beta Was this translation helpful? Give feedback.
Answered by
ChristianMurphy
Feb 24, 2022
Replies: 1 comment 1 reply
-
|
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
Sachin-chaurasiya
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
react-markdown
,rehype-raw
, andhast-util-raw
are all ES Modules.This works out of the box with Node and many build tools, a few build tools need to be configured, it looks like the build tool you are using may need to be configured.
This ESM guide offers configuration suggestions for several build tools.