Skip to content

[Feature]: Support with { type: 'bytes' } imports #11881

@chenjiahan

Description

@chenjiahan

What problem does this feature solve?

Support the new Import Bytes proposal — allowing developers to import raw binary files directly as Uint8Array.

References

What does the proposed API of configuration look like?

Example:

import buf from "./a.png" with { type: "bytes" };

console.log(buf instanceof Uint8Array); // true

Metadata

Metadata

Assignees

Labels

teamThe issue/pr is created by the member of Rspack.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions