Skip to content

[Bug]: CJS interop factory shadowed when re-bundling rolldown-emitted CJS output #9055

@sapphi-red

Description

@sapphi-red

Reproduction link or steps

REPL

What is expected?

The output to not have const require_greet = require_greet();.

What is actually happening?

The output has const require_greet = require_greet(); which causes TDZ error.

System Info

REPL 1.0.0-rc.15

Any additional comments?

Originally reported at vitejs/vite#22176

Metadata

Metadata

Assignees

Type

Priority

None yet

Effort

None yet

Projects

Status
Done

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions