Skip to content

Added type=module to @ffmpeg/util package.json #627

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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Dec 24, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions packages/util/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
"version": "0.12.1",
"description": "browser utils for @ffmpeg/*",
"main": "./dist/cjs/index.js",

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With type set to module, these file extensions will either need to be .cjs or have a package.json file created in their respective ./cjs folder that has its type set to commonjs. Otherwise the module resolution API will treat them all as ESM.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is quiet hard to find a perfect solution for building and bundling, will test and see if tsup is better in this scenario if I have time. Thanks!

"type": "module",
"types": "./dist/cjs/index.d.ts",
"exports": {
".": {
Expand Down