Skip to content

Commit

Permalink
use vscode-remote-endpoint when importing scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
jrieken committed Aug 14, 2019
1 parent 2b4278f commit b2b0c86
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion src/vs/workbench/api/worker/extHostExtensionService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ import * as vscode from 'vscode';
import { TernarySearchTree } from 'vs/base/common/map';
import { nullExtensionDescription } from 'vs/workbench/services/extensions/common/extensions';
import { ExtensionDescriptionRegistry } from 'vs/workbench/services/extensions/common/extensionDescriptionRegistry';
import { isWeb } from 'vs/base/common/platform';
import { URI } from 'vs/base/common/uri';

class ApiInstances {

Expand Down Expand Up @@ -83,8 +85,14 @@ export class ExtHostExtensionService extends AbstractExtHostExtensionService {
};

try {
// todo@joh this is a copy of `dom.ts#asDomUri`
// build url of the things we resolve
const url = isWeb
? URI.parse(window.location.href).with({ path: '/vscode-remote', query: JSON.stringify(URI.file(modulePath)) }).toString(true)
: modulePath;

activationTimesBuilder.codeLoadingStart();
importScripts(modulePath);
importScripts(url);
} finally {
activationTimesBuilder.codeLoadingStop();
}
Expand Down

0 comments on commit b2b0c86

Please sign in to comment.