简体   繁体   English

VS Code扩展API:是否可以扩展/增强现有的文件资源管理器?

[英]VS Code extension API: Is it possible to extend/enhance the existing file explorer?

I have an idea of a plugin that would require modifying the VS Code file explorer visually. 我有一个插件的想法,需要视觉上修改VS Code文件浏览器。 Is there any way to access the view through the extension API? 有什么方法可以通过扩展API访问视图?

I'm aware that there is an API for adding new tree views ( https://code.visualstudio.com/docs/extensionAPI/extension-points#_contributesviews ) but I've found no mention of being able to customize the existing one. 我知道有一个用于添加新树视图的API( https://code.visualstudio.com/docs/extensionAPI/extension-points#_contributesviews ),但是我没有提到能够自定义现有树视图。

from vscode in github : 来自github中的 vscode:

There are no plans to give access to the dom for various reasons explained here: https://code.visualstudio.com/docs/extensions/our-approach 由于各种原因,没有计划允许访问dom的原因在这里说明: https : //code.visualstudio.com/docs/extensions/our-approach

... ...

we do not provide direct access to the underlying UI DOM to extension writers. 我们不向扩展编写者提供对底层UI DOM的直接访问。

The approach to run the extensions isolated in a separate process allows VS Code to strictly control the API exposed to extenders. 在单独的过程中隔离运行扩展的方法允许VS Code严格控制扩展程序公开的API。 See the Extensibility API Overview for details on the current API. 有关当前API的详细信息,请参见“扩展性API概述”。

Is there any way to access the view through the extension API? 有什么方法可以通过扩展API访问视图?

No. The extensions run in their own process and do not have direct access to the UI dom. 不能。扩展程序以自己的方式运行,并且不能直接访问UI dom。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM