Skip to content

Webview: isSupportedLink() needs to check for running inside web or not #79647

@bpasero

Description

@bpasero

Stumbled upon this code:

private isSupportedLink(webview: WebviewEditorInput, link: URI): boolean {
	if (MainThreadWebviews.standardSupportedLinkSchemes.has(link.scheme)) {
		return true;
	}
	if (this._productService.urlProtocol === link.scheme) {
		return true;
	}
	return !!webview.webview.contentOptions.enableCommandUris && link.scheme === 'command';
}

_productService.urlProtocol is not making a lot of sense when running from the Web UI, it is in fact set to be an empty string currently.

Metadata

Metadata

Assignees

Labels

debtCode quality issueswebIssues related to running VSCode in the web

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions