Skip to content

[Feature Request]: remove "use strict" for an empty file #2826

Description

@sapphi-red

Reproduction link or steps

  1. Open https://stackblitz.com/edit/github-xv4yss-bkwjee?file=rolldown.config.mjs,src%2Fdynamic.js
  2. npm run build runs automatically
  3. dist/dynamic-DTI2egmw.js is an empty file with "use strict";. But if it's empty "use strict"; can be removed.

What is expected?

dist/dynamic-DTI2egmw.js to be a completely empty file without "use strict";.

What is actually happening?

dist/dynamic-DTI2egmw.js contains "use strict";.

System Info

Stackblitz

  System:
    OS: Linux 5.0 undefined
    CPU: (8) x64 Intel(R) Core(TM) i9-9880H CPU @ 2.30GHz
    Memory: 0 Bytes / 0 Bytes
    Shell: 1.0 - /bin/jsh
  Binaries:
    Node: 18.20.3 - /usr/local/bin/node
    Yarn: 1.22.19 - /usr/local/bin/yarn
    npm: 10.2.3 - /usr/local/bin/npm
    pnpm: 8.15.6 - /usr/local/bin/pnpm
  npmPackages:
    rolldown: https://pkg.pr.new/rolldown@01cedb9 => 0.14.0

Any additional comments?

No response

Metadata

Metadata

Assignees

Type

No type

Fields

Priority

None yet

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions