- Notifications
You must be signed in to change notification settings - Fork622
fix: built file references undeclared import_foo$n#4745
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
netlifybot commentedMay 30, 2025 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
✅ Deploy Preview forrolldown-rs canceled.
|
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.
Pull Request Overview
This PR ("fix: 4740") introduces updates to test snapshots and several test files for CommonJS compatibility along with minor changes in the code splitting and scope hoisting stages. Key changes include:
- Updating snapshot metadata for file naming with hash.
- Adding new test files under the partial_cjs_ns_merge_2 directory.
- Inserting debug statements in the code splitting stage and refining conditions in scope hoisting.
Reviewed Changes
Copilot reviewed 10 out of 11 changed files in this pull request and generated no comments.
File | Description |
---|---|
crates/rolldown/tests/snapshots/integration_rolldown__filename_with_hash.snap | Updated snapshot to reflect new test output for module renaming. |
crates/rolldown/tests/rolldown/cjs_compat/partial_cjs_ns_merge_2/* | New test files added to exercise partial CommonJS namespace merge behavior. |
crates/rolldown/src/stages/generate_stage/code_splitting.rs | Added debugging statements which may have been left in unintentionally. |
crates/rolldown/src/module_finalizers/scope_hoisting/mod.rs | Refined conditional check for merging CJS namespaces. |
Files not reviewed (1)
- pnpm-lock.yaml: Language not supported
Comments suppressed due to low confidence (4)
crates/rolldown/tests/rolldown/cjs_compat/partial_cjs_ns_merge_2/main.js:4
- The variable 'Typography' is referenced but not defined in the code. Either define 'Typography' or remove it from the log statement.
console.log('r', React, Typography, toArray);
crates/rolldown/tests/rolldown/cjs_compat/partial_cjs_ns_merge_2/lib.js:5
- The variable 'ret' is used without a prior definition. Define and populate 'ret' or return a correctly defined value.
return ret;
crates/rolldown/src/stages/generate_stage/code_splitting.rs:192
- [nitpick] Debug statements like dbg! should be removed before committing production code.
dbg!(&self.link_output.module_table[*k].id());
crates/rolldown/src/stages/generate_stage/code_splitting.rs:204
- [nitpick] Consider removing this debug statement to avoid leaving development code in production.
dbg!(&self.link_output.module_table[owner].id());
cb3f613
to9362bcd
CompareBenchmarks Rust
|
cb30e40
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Description
import_foo$n
#4740