Skip to content

TypeError: randomUUID is not a function #406

@xsunnydong

Description

@xsunnydong
  • cnpm install
    TypeError: randomUUID is not a function
    at formatInstallOptions (/usr/local/lib/node_modules/cnpm/node_modules/npminstall/lib/format_install_options.js:127:33)
    at module.exports (/usr/local/lib/node_modules/cnpm/node_modules/npminstall/lib/local_install.js:54:13)
    at /usr/local/lib/node_modules/cnpm/node_modules/npminstall/bin/install.js:397:11
    npminstall version: 6.3.0
    cnpm的依赖npminstall 6.3.0 这一版本有问题 cnpm install 时报错 npminstall 退回到6.2.0版本问题解决
    按照官方文档 https://www.npmjs.com/package/randomuuid randomUUID 在v15.6.0引入 !
    Polyfill for the crypto.randomUUID() method as proposed in the WICG randomUUID specification and recently implemented in Node.js v15.6.0.

node 版本 v14.5.0
npm 版本 6.14.5
yarn 版本 1.22.4

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions