Socket
Socket
Sign inDemoInstall

@vscode/test-web

Package Overview
Dependencies
Maintainers
7
Versions
54
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@vscode/test-web - npm Package Compare versions

Comparing version 0.0.47 to 0.0.48

fs-provider/package-lock.json

8

fs-provider/package.json

@@ -39,5 +39,5 @@ {

"@types/vscode": "^1.81.0",
"@types/webpack-env": "^1.18.2",
"ts-loader": "^9.4.4",
"webpack": "^5.88.2",
"@types/webpack-env": "^1.18.3",
"ts-loader": "^9.5.0",
"webpack": "^5.89.0",
"webpack-cli": "^5.1.4",

@@ -47,4 +47,4 @@ "process": "^0.11.10",

"request-light": "^0.7.0",
"vscode-uri": "^3.0.7"
"vscode-uri": "^3.0.8"
}
}

@@ -25,5 +25,8 @@ "use strict";

origin: (ctx) => {
if (/^https:\/\/[^.]+\.vscode-cdn\.net$/.test(ctx.get('Origin')) || // needed for the webviewContent
/^https:\/\/[^.]+\.vscode-webview\.net$/.test(ctx.get('Origin'))) {
return ctx.get('Origin');
const origin = ctx.get('Origin');
if (/^https:\/\/[^.]+\.vscode-cdn\.net$/.test(origin) || // needed for the webviewContent
/^https:\/\/[^.]+\.vscode-webview\.net$/.test(origin) ||
new RegExp(`^${ctx.protocol}://[^.]+\\.${ctx.host}$`).test(origin) // match subdomains of localhost
) {
return origin;
}

@@ -33,3 +36,3 @@ return undefined;

}));
if (config.build.type !== 'sources') {
if (config.build.type !== 'sources' && config.build.type !== 'static') {
// CSP: frame-ancestors

@@ -36,0 +39,0 @@ app.use((ctx, next) => {

@@ -114,6 +114,14 @@ "use strict";

const productOverrides = await getProductOverrides(config.build.location);
ctx.state.workbench = new Workbench(`${ctx.protocol}://${ctx.host}/static/sources`, true, config.esm, builtInExtensions, productOverrides);
ctx.state.workbench = new Workbench(`${ctx.protocol}://${ctx.host}/static/sources`, true, config.esm, builtInExtensions, {
...productOverrides,
webEndpointUrlTemplate: `${ctx.protocol}://{{uuid}}.${ctx.host}/static/sources`,
webviewContentExternalBaseUrlTemplate: `${ctx.protocol}://{{uuid}}.${ctx.host}/static/sources/out/vs/workbench/contrib/webview/browser/pre/`
});
}
else if (config.build.type === 'static') {
ctx.state.workbench = new Workbench(`${ctx.protocol}://${ctx.host}/static/build`, false, config.esm);
const baseUrl = `${ctx.protocol}://${ctx.host}/static/build`;
ctx.state.workbench = new Workbench(baseUrl, false, config.esm, [], {
webEndpointUrlTemplate: `${ctx.protocol}://{{uuid}}.${ctx.host}/static/build`,
webviewContentExternalBaseUrlTemplate: `${ctx.protocol}://{{uuid}}.${ctx.host}/static/build/out/vs/workbench/contrib/webview/browser/pre/`
});
}

@@ -120,0 +128,0 @@ else if (config.build.type === 'cdn') {

{
"name": "@vscode/test-web",
"version": "0.0.47",
"version": "0.0.48",
"scripts": {
"install-extensions": "yarn --cwd=fs-provider && yarn --cwd=sample",
"compile": "tsc -p ./ && yarn compile-fs-provider",
"install-extensions": "npm i --prefix=fs-provider && npm i --prefix=sample",
"compile": "tsc -p ./ && npm run compile-fs-provider",
"watch": "tsc -w -p ./",
"prepack": "yarn compile",
"prepack": "npm run compile",
"test": "eslint src --ext ts && tsc --noEmit",
"preversion": "npm test",
"postversion": "git push && git push --tags",
"compile-fs-provider": "yarn --cwd=fs-provider compile-web",
"compile-sample": "yarn --cwd=sample compile-web",
"compile-fs-provider": "npm run --prefix=fs-provider compile-web",
"compile-sample": "npm run --prefix=sample compile-web",
"sample": "npm run compile && npm run compile-sample && node . --extensionDevelopmentPath=sample sample/test-workspace",

@@ -26,3 +26,3 @@ "sample-tests": "npm run compile && npm run compile-sample && node . --extensionDevelopmentPath=sample --extensionTestsPath=sample/dist/web/test/suite/index.js --headless=true sample/test-workspace",

"dependencies": {
"@koa/router": "^12.0.0",
"@koa/router": "^12.0.1",
"@koa/cors": "^4.0.0",

@@ -34,5 +34,5 @@ "koa": "^2.14.2",

"minimist": "^1.2.8",
"playwright": "^1.38.1",
"@playwright/browser-chromium": "^1.38.1",
"vscode-uri": "^3.0.7",
"playwright": "^1.39.0",
"@playwright/browser-chromium": "^1.39.0",
"vscode-uri": "^3.0.8",
"http-proxy-agent": "^7.0.0",

@@ -44,14 +44,14 @@ "https-proxy-agent": "^7.0.2",

"devDependencies": {
"@types/koa": "^2.13.9",
"@types/koa-morgan": "^1.0.6",
"@types/koa-mount": "^4.0.3",
"@types/koa-static": "^4.0.2",
"@types/koa__router": "^12.0.1",
"@types/minimist": "^1.2.3",
"@types/node": "^20.8.4",
"@types/gunzip-maybe": "^1.4.0",
"@types/tar-fs": "^2.0.2",
"@typescript-eslint/eslint-plugin": "^6.7.3",
"@typescript-eslint/parser": "^6.7.3",
"eslint": "^8.51.0",
"@types/koa": "^2.13.10",
"@types/koa-morgan": "^1.0.7",
"@types/koa-mount": "^4.0.4",
"@types/koa-static": "^4.0.3",
"@types/koa__router": "^12.0.3",
"@types/minimist": "^1.2.4",
"@types/node": "^20.8.9",
"@types/gunzip-maybe": "^1.4.1",
"@types/tar-fs": "^2.0.3",
"@typescript-eslint/eslint-plugin": "^6.9.0",
"@typescript-eslint/parser": "^6.9.0",
"eslint": "^8.52.0",
"eslint-plugin-header": "^3.1.1",

@@ -58,0 +58,0 @@ "typescript": "^5.2.2"

@@ -93,9 +93,9 @@ # @vscode/test-web

- `yarn && yarn install-extensions`
- `npm i && npm run install-extensions`
- Make necessary changes in [`src`](./src)
- `yarn compile` (or `yarn watch`)
- `npm run compile` (or `npm run watch`)
- run `yarn sample` to launch VS Code Browser with the `sample` extension bundled in this repo.
- run `npm run sample` to launch VS Code Browser with the `sample` extension bundled in this repo.
- run `yarn sample-tests` to launch VS Code Browser running the extension tests of the `sample` extension bundled in this repo.
- run `npm run sample-tests` to launch VS Code Browser running the extension tests of the `sample` extension bundled in this repo.

@@ -102,0 +102,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc