fix: prune react-core rsc render internals#1829
Open
ErnestM1234 wants to merge 1 commit into
Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Verification
Caveat
Greptile Summary
This PR prunes dead internal exports from the
@generaltranslation/react-core/components-rscentrypoint, removing pre-instantiated RSC render pipeline helpers and their associated types that were never re-exported by downstream consumers.renderDefaultChildren,renderPreparedT,renderTranslatedChildren,renderVariable,createRenderVariable,prepareT, andgetShouldTranslatefrom the public entrypoint, along with theRenderDefaultChildrenArgs,RenderPreparedTParams, andRenderTranslatedChildrenArgstype exports.createRenderPipelineand theRenderPipelinetype, which are consumed bygt-react's RSC surface (index.rsc.tsline 89) and thegt-nextbuild-time render pipeline.Confidence Score: 5/5
Safe to merge — the removed exports were internal-only helpers with no downstream consumers in gt-react or gt-next.
All removed exports (getShouldTranslate, prepareT, createRenderVariable, the four pre-instantiated render pipeline functions, and three arg types) are not re-exported by any downstream package. gt-react's index.rsc.ts only consumes createRenderPipeline and RenderPipeline, both of which are kept. The gt-next build-time renderPipeline.ts imports createRenderPipeline via gt-react and is unaffected. Tests are properly updated to assert absence of the pruned symbols.
No files require special attention.
Important Files Changed
Flowchart
%%{init: {'theme': 'neutral'}}%% flowchart TD A["gt-react / gt-next consumers"] -->|"import createRenderPipeline, RenderPipeline"| B["gt-react/index.rsc.ts"] B -->|"re-exports createRenderPipeline"| C["react-core/components-rsc.ts"] C -->|"kept"| D["createRenderPipeline\nRenderPipeline type"] C -->|"removed in this PR"| E["getShouldTranslate\nprepareT\ncreateRenderVariable\nrenderDefaultChildren\nrenderTranslatedChildren\nrenderVariable\nrenderPreparedT\nRenderDefaultChildrenArgs\nRenderPreparedTParams\nRenderTranslatedChildrenArgs"] style E fill:#f8d7da,stroke:#dc3545 style D fill:#d4edda,stroke:#28a745%%{init: {'theme': 'base', 'themeVariables': {"darkMode": true, "background": "#0d1117", "primaryColor": "#21262d", "primaryTextColor": "#e6edf3", "primaryBorderColor": "#8b949e", "lineColor": "#8b949e", "textColor": "#e6edf3", "edgeLabelBackground": "#161b22", "actorBkg": "#21262d", "actorBorder": "#8b949e", "actorTextColor": "#e6edf3", "actorLineColor": "#8b949e", "signalColor": "#8b949e", "signalTextColor": "#e6edf3", "noteBkgColor": "#373320", "noteBorderColor": "#d4a72c", "noteTextColor": "#f0e6c0", "labelBoxBkgColor": "#21262d", "labelBoxBorderColor": "#8b949e", "labelTextColor": "#e6edf3", "loopTextColor": "#e6edf3", "activationBkgColor": "#30363d", "activationBorderColor": "#8b949e"}}}%% flowchart TD A["gt-react / gt-next consumers"] -->|"import createRenderPipeline, RenderPipeline"| B["gt-react/index.rsc.ts"] B -->|"re-exports createRenderPipeline"| C["react-core/components-rsc.ts"] C -->|"kept"| D["createRenderPipeline\nRenderPipeline type"] C -->|"removed in this PR"| E["getShouldTranslate\nprepareT\ncreateRenderVariable\nrenderDefaultChildren\nrenderTranslatedChildren\nrenderVariable\nrenderPreparedT\nRenderDefaultChildrenArgs\nRenderPreparedTParams\nRenderTranslatedChildrenArgs"] style E fill:#f8d7da,stroke:#dc3545 style D fill:#d4edda,stroke:#28a745Reviews (1): Last reviewed commit: "fix: prune react-core rsc render interna..." | Re-trigger Greptile