-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ckeditor5-image augmentation not "resolved" when using moduleResolution NodeNext #15880
Closed
Sanderovich opened this issue
Feb 19, 2024
· 1 comment
· Fixed by ckeditor/ckeditor5-linters-config#31, #15978 or ckeditor/ckeditor5-linters-config#32
Closed
ckeditor5-image augmentation not "resolved" when using moduleResolution NodeNext #15880
Sanderovich opened this issue
Feb 19, 2024
· 1 comment
· Fixed by ckeditor/ckeditor5-linters-config#31, #15978 or ckeditor/ckeditor5-linters-config#32
Labels
domain:ts
squad:core
Issue to be handled by the Core team.
type:bug
This issue reports a buggy (incorrect) behavior.
Milestone
Comments
filipsobol
added a commit
that referenced
this issue
Mar 4, 2024
Fix (image,list): Fix TypeScript augmentation. Closes #15880.
Fix present in the next release. |
psmyrek
added a commit
to ckeditor/ckeditor5-linters-config
that referenced
this issue
Mar 5, 2024
…xtensions-in-imports Fix (eslint-plugin-ckeditor5-rules): Report a missing file extension when '.' import or export is used. Fixes [#15880](ckeditor/ckeditor5#15880). Fix (eslint-plugin-ckeditor5-rules): Properly detect valid imports of dependencies using the `exports` field.
psmyrek
added a commit
to ckeditor/ckeditor5-linters-config
that referenced
this issue
Mar 8, 2024
…e-extensions-in-imports Fix (eslint-plugin-ckeditor5-rules): Improve autofixer for `'.'` imports to prepare a relative path to the `index.js` file rather than an absolute path to the imported file. Closes ckeditor/ckeditor5#15880.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
domain:ts
squad:core
Issue to be handled by the Core team.
type:bug
This issue reports a buggy (incorrect) behavior.
📝 Reproduction details
I created a repository to demonstrate the bug https://github.com/Sanderovich/ckeditor5-41.1-module-resolution-reproduction. See the commits for the working situation and the reproduction.
Currently, I am updating CKEditor 5 version 40.2 to 41.1, and I am getting Typescript errors when getting the ImageUtils.
const imageUtils = this.editor.plugins.get('ImageUtils') // results in type PluginInterface
(See repo, file src/ckeditor.ts, line 41, error reproduction state). I have found that the errors could be caused by the moduleResolution setting in our tsconfig.ts. Currently, it is on NodeNext, and when I change it to bundler, Typescript is happy. However, this has never been a problem before, and we have the preference to keep using NodeNext✔️ Expected result
this.editor.plugins.get('ImageUtils')
resulting in aImageUtils
type.❌ Actual result
this.editor.plugins.get('ImageUtils')
resulting in aPluginInterface
type.❓ Possible solution
Something that worked for me is to change the import in
@ckeditor5/ckeditor5-image/src/augmentation.d.ts
to import from '/index.js'
instead of'.'
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: