-
-
Notifications
You must be signed in to change notification settings - Fork 268
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
feat: support rspack modern ssr #2775
Conversation
@squadronai review |
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.
Summary
This pull request adds support for Rspack modern SSR (Server-Side Rendering) to the project. The key changes include:
-
Modifications to the TypeScript configuration object in the
dts-plugin
package to extract and removepaths
andbaseUrl
from the compiler options, construct a list of files to compile (including exposed components, .d.ts files, and additional files), and update the configuration'sinclude
,files
, andexclude
properties. -
Addition of a hook to the compilation process in the
enhanced
package'sConsumeSharedPlugin.ts
file. This hook sets up a dependency factory forConsumeSharedFallbackDependency
and uses thethisCompilation
hook to access thecompilation
andnormalModuleFactory
objects.
These changes aim to integrate the Rspack modern SSR functionality into the existing codebase, providing support for this new feature.
File Summaries
File | Summary |
---|---|
packages/dts-plugin/src/core/configurations/remotePlugin.ts | The code modifies a TypeScript configuration object by extracting and removing 'paths' and 'baseUrl' from compiler options. It then constructs a list of files to compile, including exposed components, .d.ts files, and additional files. Finally, it updates the configuration's include, files, and exclude properties. |
packages/enhanced/src/lib/sharing/ConsumeSharedPlugin.ts | The code adds a hook to the compilation process, setting up a dependency factory for ConsumeSharedFallbackDependency. It uses the thisCompilation hook to access the compilation and normalModuleFactory objects. |
Commits reviewed:
0de1c8365c73245995c5d5b5e68cbda00046b6de...435070a23b2edd948cdf953d05440acce8f7f845
435070a23b2edd948cdf953d05440acce8f7f845...66c1d3773d35ad01fb4bba1150f2ed1a4c4bf40c
66c1d3773d35ad01fb4bba1150f2ed1a4c4bf40c...af44dfe20bbe3098420b3e67720cc4b1f8ff246d
af44dfe20bbe3098420b3e67720cc4b1f8ff246d...bce12593136aadc52d16ef2695c53c6b01908693
af44dfe20bbe3098420b3e67720cc4b1f8ff246d...bce12593136aadc52d16ef2695c53c6b01908693
af44dfe20bbe3098420b3e67720cc4b1f8ff246d...bce12593136aadc52d16ef2695c53c6b01908693
Description
support rspack ssr
Related Issue
Types of changes
Checklist