-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
Closed
Labels
squad:platformIssue to be handled by the Platform team.Issue to be handled by the Platform team.type:featureThis issue reports a feature request (an idea for a new functionality or a missing option).This issue reports a feature request (an idea for a new functionality or a missing option).
Milestone
Description
📝 Provide a description of the new feature
This is a followup for another issue: #18804
In #18750, we have added a validator that prevents the introduction of regression related to this issue - #18583.
We agreed to export a plugin class as a value instead of a type.
Unfortunately, we do not have any rule that forces it.
Definition of Done
Let's use the following file as an example:
export { Bold } from './bold.js'; |
After applying the following change:
diff --git a/packages/ckeditor5-basic-styles/src/index.ts b/packages/ckeditor5-basic-styles/src/index.ts
index 5cf0a7bcbf..f3dd063082 100644
--- a/packages/ckeditor5-basic-styles/src/index.ts
+++ b/packages/ckeditor5-basic-styles/src/index.ts
@@ -7,7 +7,7 @@
* @module basic-styles
*/
-export { Bold } from './bold.js';
+export type { Bold } from './bold.js';
export { BoldEditing } from './bold/boldediting.js';
export { BoldUI } from './bold/boldui.js';
export { Code } from './code.js';
And executing: node scripts/ci/validate-module-re-exports.mjs
, I would expect an error. In the current implementation it does not list it as an error.
Metadata
Metadata
Assignees
Labels
squad:platformIssue to be handled by the Platform team.Issue to be handled by the Platform team.type:featureThis issue reports a feature request (an idea for a new functionality or a missing option).This issue reports a feature request (an idea for a new functionality or a missing option).