-
-
Notifications
You must be signed in to change notification settings - Fork 266
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
chore(rsbuild-plugin): split setUp function to help extend #3215
Changes from all commits
2f4fef8
f9f5c25
19abee0
2423db9
d0074b0
cd5269c
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'@module-federation/rsbuild-plugin': patch | ||
--- | ||
|
||
chore(rsbuild-plugin): split setUp function to help extend |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'@module-federation/storybook-addon': patch | ||
--- | ||
|
||
chore: export plugin name |
Original file line number | Diff line number | Diff line change | ||||
---|---|---|---|---|---|---|
@@ -1,5 +1,8 @@ | ||||||
import type { moduleFederationPlugin } from '@module-federation/sdk'; | ||||||
export { default as ModuleFederationPlugin } from './wrapper/ModuleFederationPlugin'; | ||||||
export { | ||||||
default as ModuleFederationPlugin, | ||||||
PLUGIN_NAME, | ||||||
} from './wrapper/ModuleFederationPlugin'; | ||||||
export { default as ContainerReferencePlugin } from './wrapper/ContainerReferencePlugin'; | ||||||
export { default as SharePlugin } from './wrapper/SharePlugin'; | ||||||
export { default as ContainerPlugin } from './wrapper/ContainerPlugin'; | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The export statement for ContainerPlugin appears to be truncated. Complete the line to properly export the plugin:
Suggested change
Comment on lines
1
to
8
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Consider adding JSDoc comments for the exported plugins to improve API documentation. This will help users understand the purpose and usage of each plugin. For example:
Also consider grouping related exports together with explanatory comments for better code organization. |
||||||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,4 @@ | ||
export { ModuleFederationPlugin } from '@module-federation/rspack/plugin'; | ||
export { | ||
ModuleFederationPlugin, | ||
PLUGIN_NAME, | ||
} from '@module-federation/rspack/plugin'; |
Original file line number | Diff line number | Diff line change | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
@@ -1,3 +1,6 @@ | ||||||||||||
import { default as ModuleFederationPlugin } from './wrapper/ModuleFederationPlugin'; | ||||||||||||
import { | ||||||||||||
default as ModuleFederationPlugin, | ||||||||||||
PLUGIN_NAME, | ||||||||||||
} from './wrapper/ModuleFederationPlugin'; | ||||||||||||
|
||||||||||||
Comment on lines
+1
to
+4
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The import statement could be more specific about what's being imported. Instead of using 'default as', consider importing the plugin directly for better clarity and readability. Here's a suggested change:
Suggested change
This makes it immediately clear what's being imported without the 'default as' indirection. |
||||||||||||
export { ModuleFederationPlugin }; | ||||||||||||
export { ModuleFederationPlugin, PLUGIN_NAME }; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The import statement only imports the type but not the actual module. If the module is needed at runtime, consider importing both: