是否可以为 Visual Studio 代码智能感知/自动完成定义自定义 npm 注册表? [英] Is it possible to define a custom npm registry for visual studio code intellisense/autocompletion?

查看:46
本文介绍了是否可以为 Visual Studio 代码智能感知/自动完成定义自定义 npm 注册表?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们有一个自定义的 npm 注册表(通过 npm config set registry http://our.url/path 指定),它也需要登录(npm login --registry=http://our.url/path)

we have a custom npm registry (specified via npm config set registry http://our.url/path) that also requires a login (npm login --registry=http://our.url/path)

在 package.json 的依赖项中输入名称时,VS Code 会显示 npm 包名称的自动完成(智能感知).它还显示了这些软件包的最新版本.但是,这只适用于公开发布的软件包.

VS Code shows auto completion (intellisense) for npm package names when typing in names in package.json's dependencies. It also shows latest versions for those packages there too. However this only works with public released packages.

由于我们使用的是自定义 npm registry,如何让 VS Code 支持我们自己的 npm 包的自动补全,这些包只在我们自己的 registry 上发布(包括版本号)?

As we are using a custom npm registry, how to get VS Code to support auto completion for our own npm packages that only have been published on our own registry (including version number)?

谢谢,托本

推荐答案

不,目前这是不可能的,它被硬编码到 这个文件.

No, this is not currently possible, it is hard coded to the official registry in this file.

您可以在 https://www.GitHub.com/打开功能请求微软/vscode/问题/新

这篇关于是否可以为 Visual Studio 代码智能感知/自动完成定义自定义 npm 注册表?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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