ckeditor5-react does not work with optimized imports #17533
Labels
domain:dx
This issue reports a developer experience problem or possible improvement.
domain:integration-dx
This issue reports a problem with the developer experience when integrating CKEditor into a system.
type:bug
This issue reports a buggy (incorrect) behavior.
Milestone
📝 Provide detailed reproduction steps (if any)
Using optimized imports with
@ckeditor/ckeditor5-react
results in incompatible type errors in TypeScript.I modified the Headless editor demo to include an optimized import to
@ckeditor/ckeditor5-core
and I get build errors.✔️ Expected result
No build errors.
❌ Actual result
❓ Possible solution
Switching the import from
'@ckeditor/ckeditor5-core/dist/index.js'
to'@ckeditor/ckeditor5-core/src/index.js'
seems to resolve the build time error, but this required all imports to now point tosrc
instead ofdist
, and this resulted in runtime errors:This is actually the point I started from. I was previously using optimized imports before trying to upgrade with new installation methods when I ran into #17504. Upgrading without using the new installation method resulted in the same runtime error as above. I noticed that I was importing from
src
instead ofdist
so I tried updating all the imports and instead ran into the TS build error.If you'd like to see this fixed sooner, add a 👍 reaction to this post.
The text was updated successfully, but these errors were encountered: