Skip to content

Updating cli from 6.9.3 → 6.10.1 SyntaxError: Unexpected token 'export' #4499

Description

@thenaim

Description:
After update getting error

Steps to Reproduce:

  1. install latest version ionic cli
npm i -g @ionic/cli@latest
  1. check version or serve your project
ionic -v

Output:

bossjon@boss:~$ ionic -v
6.10.1
/usr/local/lib/node_modules/@ionic/cli/node_modules/uuid/dist/esm-browser/index.js:1

export { default as v1 } from './v1.js';
^^^^^^

SyntaxError: Unexpected token 'export'
at wrapSafe (internal/modules/cjs/loader.js:1053:16)
at Module._compile (internal/modules/cjs/loader.js:1101:27)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1157:10)
at Module.load (internal/modules/cjs/loader.js:985:32)
at Function.Module._load (internal/modules/cjs/loader.js:878:14)
at Module.require (internal/modules/cjs/loader.js:1025:19)
at require (internal/modules/cjs/helpers.js:72:18)
at Object.<anonymous> (/usr/local/lib/node_modules/@ionic/cli/lib/utils/uuid.js:3:16)
at Module._compile (internal/modules/cjs/loader.js:1137:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1157:10)

My ionic info:

bossjon@boss:~$ ionic info
/usr/local/lib/node_modules/@ionic/cli/node_modules/uuid/dist/esm-browser/index.js:1

export { default as v1 } from './v1.js';
^^^^^^

SyntaxError: Unexpected token 'export'
at wrapSafe (internal/modules/cjs/loader.js:1053:16)
at Module._compile (internal/modules/cjs/loader.js:1101:27)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1157:10)
at Module.load (internal/modules/cjs/loader.js:985:32)
at Function.Module._load (internal/modules/cjs/loader.js:878:14)
at Module.require (internal/modules/cjs/loader.js:1025:19)
at require (internal/modules/cjs/helpers.js:72:18)
at Object.<anonymous> (/usr/local/lib/node_modules/@ionic/cli/lib/utils/uuid.js:3:16)
at Module._compile (internal/modules/cjs/loader.js:1137:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1157:10)
[WARN] You are not in an Ionic project directory. Project context may be missing.

Ionic:

   Ionic CLI : 6.10.1

Utility:

   cordova-res : not installed
   native-run  : not installed

System:

   NodeJS : v12.18.3
   npm    : 6.14.6
   OS     : Linux 5.4

Ps: Other versions works fine.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions