[BUG] Plugins and Remix v2.9.1: Error [ERR_REQUIRE_ESM]: require() of ES Module /node_modules/@mdxeditor/editor/dist/index.js not supported.
#441
Labels
bug
Something isn't working
If you want to ask for support or request features, sponsor the project and contact me over email.
Describe the bug
It's not a bug, but a really PITA for installation with Remix, related to CJS / ESM
I started from indie stack: https://github.com/remix-run/indie-stack
here is the important files I think:
package.json
I needed to install manually
parse-entities
andlexical
tsconfig.json
just here to let you know
vite.config.ts
the pita here was to add this
remix.config.js
same as the
vite.config.ts
but forserverDependenciesToBundle
fieldMDXCustomEditor.tsx
I added all the possible extensions there, inspired from your Live demo https://github.com/mdx-editor/editor/blob/main/src/examples/site-demo.tsx
finally I used it this way,
I just want to open the issue here to
once it's installed, it's a fabulous job you did there! much better and easier than draft.js or slate
thanks !
The text was updated successfully, but these errors were encountered: