mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-27 20:13:32 +01:00
Merge pull request #75741 from microsoft/dev/mjbvz/webviewResourceRoot
Add vscode.env.webviewResourceRoot API
This commit is contained in:
@@ -58,6 +58,7 @@ export interface IEnvironment {
|
||||
extensionTestsLocationURI?: URI;
|
||||
globalStorageHome: URI;
|
||||
userHome: URI;
|
||||
webviewResourceRoot: string;
|
||||
}
|
||||
|
||||
export interface IStaticWorkspaceData {
|
||||
|
||||
@@ -259,7 +259,11 @@ export function createApiFactory(
|
||||
},
|
||||
openExternal(uri: URI) {
|
||||
return extHostWindow.openUri(uri, { allowTunneling: !!initData.remoteAuthority });
|
||||
}
|
||||
},
|
||||
get webviewResourceRoot() {
|
||||
checkProposedApiEnabled(extension);
|
||||
return initData.environment.webviewResourceRoot;
|
||||
},
|
||||
};
|
||||
if (!initData.environment.extensionTestsLocationURI) {
|
||||
// allow to patch env-function when running tests
|
||||
|
||||
Reference in New Issue
Block a user