查看当前镜像
npm get registry
设置为淘宝镜像
npm config set registry https://registry.npm.taobao.org/
官方镜像
npm config set registry https://registry.n...
yekong
3年前 (2021-09-02) 1462℃
0喜欢
查看当前镜像
yarn config get registry
设置为淘宝镜像
yarn config set registry https://registry.npm.taobao.org/
设置为官方镜像
yarn config set registry https:/...
yekong
3年前 (2021-09-02) 1324℃
0喜欢
Yarn是什么?
...
yekong
3年前 (2021-09-02) 1353℃
0喜欢
Yarn是什么?
“Yarn是由Facebook、Google、Exponent 和 Tilde 联合推出了一个新的 JS 包管理工具 ,正如官方文档中写的,Yarn 是为了弥补 npm 的一些缺陷而出现的。”这句话让我想起了使用npm时的坑了:
npm install的时候慢。...
yekong
3年前 (2021-09-02) 1233℃
0喜欢
启动app.js应用程序
pm2 start app.js
模式启动4个app.js的应用实例
pm2 start app.js -i 4
启动应用程序并命名为 "api"
pm2 start app.js --name="api"
...
yekong
3年前 (2021-07-28) 1167℃
0喜欢
全局安装nodemon
npm install -g nodemon
使用
nodemon
修改文件自动重启
...
yekong
3年前 (2021-07-16) 814℃
0喜欢
在 CentOS/RHEL 8 和 Fedora 系统中,Node.js 作为 nodejs 模块而变得可用。
dnf module install nodejs:<stream>
这里的 对应了 Node.js 的主版本。 可以使用如下命令查看可用流的列表:
d...
yekong
3年前 (2021-07-16) 1250℃
0喜欢
mac 关闭所有node进程
pkill node
sudo pkill node
...
yekong
3年前 (2021-07-08) 1762℃
0喜欢
将npm源改为淘宝源后
然后重新创建项目顺利创建完成
...
yekong
3年前 (2021-01-10) 2075℃
2喜欢
npm的默认源一般都比较慢,为了能够提升npm安装依赖的速度,我们可以将源设置为国内的。
临时设置淘宝源
npm --registry https://registry.npm.taobao.org i express
永久设置淘宝源
npm conf set registry...
yekong
3年前 (2021-01-10) 358℃
0喜欢