npm install 命令下载所需包的源位置是什么? [英] What is the source location from where the npm install command downloads the required packages?

查看:214
本文介绍了npm install 命令下载所需包的源位置是什么?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试根据 package.json 文件获取命令 npm install 尝试连接的源位置 (URL) 并获取要下载的依赖包,并将其放置在本地框中.

I am trying to get the source location (URL) to which the command npm install is trying to connect and get the dependent packages to be downloaded, based on the package.json file and place it in the local box.

从下面提到的网址:http://www.tutorialspoint.com/nodejs/nodejs_npm.htm ,我开始知道它正在尝试连接 https://nodejs.org/en/

From the below mentioned url: http://www.tutorialspoint.com/nodejs/nodejs_npm.htm ,I came to know that it is trying to connect https://nodejs.org/en/

谁能告诉我上述内容是否正确,或者是否有任何其他 url 试图连接和下载软件包.

Can anyone tell me whether the above is correct or is there any other url that it is trying to connect and download the packages.

我们有一个限制互联网访问的环境.为了访问几个网址,我需要提出一个请求,允许根据代理规则访问某些网址.

We have an environment that is restricted from internet access. In order to access few urls, I need to raise a request to allow access to certain urls based on the proxy rules.

推荐答案

registry = "https://registry.npmjs.org/"

此信息可以在 npm 配置中找到.

This info can be found in the npm config.

这篇关于npm install 命令下载所需包的源位置是什么?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆