Skip to content

[Bug]: Updating from 6.1.1 to 7.3.0 ESM issues #8028

Closed as not planned
Closed as not planned
@CorySpeed

Description

@CorySpeed

Capacitor Version

Latest Dependencies:

@capacitor/cli: 7.3.0
@capacitor/core: 7.3.0
@capacitor/android: 7.3.0
@capacitor/ios: 7.3.0

Installed Dependencies:

@capacitor/cli: 7.3.0
@capacitor/core: 7.3.0
@capacitor/android: 7.3.0
@capacitor/ios: 7.3.0

Other API Details

pnpm - 9.12.3
node - v20.14.0

Platforms Affected

  • iOS
  • Android
  • Web

Current Behavior

After upgrading from 6.1.1 to 7.3.0, I get the following error when running most cap commands:

Error [ERR_REQUIRE_ESM]: require() of ES Module /........./.pnpm/brace-expansion@4.0.1/node_modules/brace-expansion/index.js from /........./.pnpm/minimatch@10.0.2/node_modules/minimatch/dist/commonjs/index.js not supported.
Instead change the require of /........./.pnpm/brace-expansion@4.0.1/node_modules/brace-expansion/index.js in /........./.pnpm/minimatch@10.0.2/node_modules/minimatch/dist/commonjs/index.js to a dynamic import() which is available in all CommonJS modules.
at Object. (/........./.pnpm/minimatch@10.0.2/node_modules/minimatch/dist/commonjs/index.js:7:43) {
code: 'ERR_REQUIRE_ESM'
}

Expected Behavior

Expected to working as intended on 6.1.1

Project Reproduction

N/A

Additional Information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions