Pana / nrm

NPM registry manager, fast switch between different registries: npm, cnpm, nj, taobao

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

require() of ES modules is not supported.

senfish opened this issue · comments

commented

nrm: 1.2.5

image

我很好奇,我进入了这个chalk地址查看一下这个包package.json,居然是5.2.0,为什么会安装最新的ES Module呢,按道理应该是V4版本的chalk

npm install nrm open@8.4.2 -g

open 这个包从 9.x 开始改成了 Native ESM,不再支持 require 的方式引入,nrm 应该锁定一下依赖到这个版本

@i5ting the version 1.2.5 published to npm is different from the source code of the master branch.

commented

@endwalker It's work for me , thank you.

试了下这个,也可以:

npm install -g Pana/nrm
commented

直接从github仓库安装:cnpm i -g nrm@git@github.com:Pana/nrm.git

use this command: npm install -g nrm open@8.4.2 --save

Try nrm i -g nrm-ng.