@multiplatform.one/vite-plugin-vscode 6.4.3 → 6.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/index.cjs +40 -2
- package/lib/index.mjs +40 -4
- package/package.json +7 -3
- package/src/index.ts +58 -3
- package/types/index.d.ts +19 -1
- package/types/index.d.ts.map +1 -1
package/lib/index.cjs
CHANGED
|
@@ -31,6 +31,8 @@ node_fs = __toESM(node_fs, 1);
|
|
|
31
31
|
let node_path = require("node:path");
|
|
32
32
|
node_path = __toESM(node_path, 1);
|
|
33
33
|
let _multiplatform_one_utils_dev = require("@multiplatform.one/utils/dev");
|
|
34
|
+
let _rolldown_plugin_babel = require("@rolldown/plugin-babel");
|
|
35
|
+
_rolldown_plugin_babel = __toESM(_rolldown_plugin_babel, 1);
|
|
34
36
|
let _tomjs_vite_plugin_vscode = require("@tomjs/vite-plugin-vscode");
|
|
35
37
|
_tomjs_vite_plugin_vscode = __toESM(_tomjs_vite_plugin_vscode, 1);
|
|
36
38
|
let _vitejs_plugin_react = require("@vitejs/plugin-react");
|
|
@@ -66,9 +68,11 @@ async function createVscodeConfig(options) {
|
|
|
66
68
|
const workspaceRoot = options.workspaceRoot ?? (0, _multiplatform_one_utils_dev.lookupProjectRoot)();
|
|
67
69
|
const isDev = options.isDev ?? process.env.NODE_ENV !== "production";
|
|
68
70
|
const { tamaguiPlugin } = await import("@tamagui/vite-plugin");
|
|
71
|
+
const outputCSS = node_path.default.join(options.targetDir, "tamagui.css");
|
|
72
|
+
if (!node_fs.default.existsSync(outputCSS)) node_fs.default.writeFileSync(outputCSS, "/* generated by @tamagui/vite-plugin during build */\n");
|
|
69
73
|
return {
|
|
70
74
|
root: options.targetDir,
|
|
71
|
-
base:
|
|
75
|
+
base: "/",
|
|
72
76
|
build: {
|
|
73
77
|
outDir: options.outDir,
|
|
74
78
|
emptyOutDir: true,
|
|
@@ -86,6 +90,7 @@ async function createVscodeConfig(options) {
|
|
|
86
90
|
(0, _multiplatform_one_utils_dev.stubExpoTypeDeclarations)(),
|
|
87
91
|
(0, _multiplatform_one_utils_dev.oneServerOnlyBrowserStub)(workspaceRoot),
|
|
88
92
|
(0, _vitejs_plugin_react.default)({ jsxRuntime: "automatic" }),
|
|
93
|
+
(0, _rolldown_plugin_babel.default)({ presets: [(0, _vitejs_plugin_react.reactCompilerPreset)()] }),
|
|
89
94
|
tamaguiPlugin({
|
|
90
95
|
components: (0, _multiplatform_one_utils_dev.lookupTamaguiModules)([options.targetDir]),
|
|
91
96
|
config: options.tamaguiConfig,
|
|
@@ -177,10 +182,41 @@ async function createVscodeConfig(options) {
|
|
|
177
182
|
}
|
|
178
183
|
};
|
|
179
184
|
}
|
|
185
|
+
/** Correct the webview dist path baked into the extension-host bundle.
|
|
186
|
+
*
|
|
187
|
+
* @tomjs/vite-plugin-vscode computes `VITE_WEBVIEW_DIST` (the segment its
|
|
188
|
+
* runtime joins onto `context.extensionUri` to form the webview base URI)
|
|
189
|
+
* by stripping `process.cwd()` off the resolved outDir. That model assumes
|
|
190
|
+
* the extension is packaged from the vite project root; with an
|
|
191
|
+
* out-of-tree staging dir (ours: apps/<name>/dist-vscode + generated
|
|
192
|
+
* manifest) the strip misses and the BUILD MACHINE'S ABSOLUTE PATH gets
|
|
193
|
+
* baked into the bundle — at runtime the webview base URI doubles into
|
|
194
|
+
* `…/dist-vscode/Users/…/dist-vscode/webview` and every asset 404s.
|
|
195
|
+
*
|
|
196
|
+
* In the staging layout the correct value is always the literal
|
|
197
|
+
* `"webview"` (the assets dir next to the generated package.json), so the
|
|
198
|
+
* staging step rewrites the joinPath call site — anchored on the
|
|
199
|
+
* `.extensionUri` property read, which survives minification. */
|
|
200
|
+
async function fixStagedWebviewAssetUris(stagingDir) {
|
|
201
|
+
const bundles = ["extension/index.js", "extension/index.cjs"].map((file) => node_path.default.join(stagingDir, file));
|
|
202
|
+
let fixed = false;
|
|
203
|
+
for (const bundle of bundles) {
|
|
204
|
+
if (!node_fs.default.existsSync(bundle)) continue;
|
|
205
|
+
const source = await node_fs.default.promises.readFile(bundle, "utf-8");
|
|
206
|
+
const rewritten = source.replace(/joinPath\(([A-Za-z_$][\w$]*\.extensionUri),\s*("[^"\n]*"|'[^'\n]*'|`[^`\n]*`)\)/g, "joinPath($1, \"webview\")");
|
|
207
|
+
if (rewritten !== source) {
|
|
208
|
+
await node_fs.default.promises.writeFile(bundle, rewritten, "utf-8");
|
|
209
|
+
fixed = true;
|
|
210
|
+
}
|
|
211
|
+
}
|
|
212
|
+
return fixed;
|
|
213
|
+
}
|
|
180
214
|
/** Write the extension-manifest package.json into the staging dir. A VS
|
|
181
215
|
* Code extension's package.json IS its manifest — the product app's own
|
|
182
216
|
* package.json (an Expo/One app manifest) can't double as it, so `vsce
|
|
183
|
-
* package` runs against the staging dir instead.
|
|
217
|
+
* package` runs against the staging dir instead. Also applies
|
|
218
|
+
* `fixStagedWebviewAssetUris` — staging is the earliest race-free point after
|
|
219
|
+
* the plugin's detached extension-host build has finished. */
|
|
184
220
|
async function writeVsceManifest(stagingDir, manifest) {
|
|
185
221
|
const { engines, main, ...rest } = manifest;
|
|
186
222
|
const packageJson = {
|
|
@@ -193,10 +229,12 @@ async function writeVsceManifest(stagingDir, manifest) {
|
|
|
193
229
|
};
|
|
194
230
|
await node_fs.default.promises.mkdir(stagingDir, { recursive: true });
|
|
195
231
|
await node_fs.default.promises.writeFile(node_path.default.join(stagingDir, "package.json"), `${JSON.stringify(packageJson, null, 2)}\n`, "utf-8");
|
|
232
|
+
await fixStagedWebviewAssetUris(stagingDir);
|
|
196
233
|
}
|
|
197
234
|
|
|
198
235
|
//#endregion
|
|
199
236
|
exports.DEFAULT_WEBVIEW_CSP = DEFAULT_WEBVIEW_CSP;
|
|
200
237
|
exports.createVscodeConfig = createVscodeConfig;
|
|
238
|
+
exports.fixStagedWebviewAssetUris = fixStagedWebviewAssetUris;
|
|
201
239
|
exports.resolveSeamOneAdapter = resolveSeamOneAdapter;
|
|
202
240
|
exports.writeVsceManifest = writeVsceManifest;
|
package/lib/index.mjs
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import fs from "node:fs";
|
|
2
2
|
import path from "node:path";
|
|
3
3
|
import { lookupProjectRoot, lookupTamaguiModules, oneServerOnlyBrowserStub, stubExpoTypeDeclarations, workspaceSourceAliases } from "@multiplatform.one/utils/dev";
|
|
4
|
+
import babel from "@rolldown/plugin-babel";
|
|
4
5
|
import vscode from "@tomjs/vite-plugin-vscode";
|
|
5
|
-
import react from "@vitejs/plugin-react";
|
|
6
|
+
import react, { reactCompilerPreset } from "@vitejs/plugin-react";
|
|
6
7
|
|
|
7
8
|
//#region src/index.ts
|
|
8
9
|
/** Default CSP: the plugin's default lacks font-src/img-src and blocks
|
|
@@ -34,9 +35,11 @@ async function createVscodeConfig(options) {
|
|
|
34
35
|
const workspaceRoot = options.workspaceRoot ?? lookupProjectRoot();
|
|
35
36
|
const isDev = options.isDev ?? process.env.NODE_ENV !== "production";
|
|
36
37
|
const { tamaguiPlugin } = await import("@tamagui/vite-plugin");
|
|
38
|
+
const outputCSS = path.join(options.targetDir, "tamagui.css");
|
|
39
|
+
if (!fs.existsSync(outputCSS)) fs.writeFileSync(outputCSS, "/* generated by @tamagui/vite-plugin during build */\n");
|
|
37
40
|
return {
|
|
38
41
|
root: options.targetDir,
|
|
39
|
-
base:
|
|
42
|
+
base: "/",
|
|
40
43
|
build: {
|
|
41
44
|
outDir: options.outDir,
|
|
42
45
|
emptyOutDir: true,
|
|
@@ -54,6 +57,7 @@ async function createVscodeConfig(options) {
|
|
|
54
57
|
stubExpoTypeDeclarations(),
|
|
55
58
|
oneServerOnlyBrowserStub(workspaceRoot),
|
|
56
59
|
react({ jsxRuntime: "automatic" }),
|
|
60
|
+
babel({ presets: [reactCompilerPreset()] }),
|
|
57
61
|
tamaguiPlugin({
|
|
58
62
|
components: lookupTamaguiModules([options.targetDir]),
|
|
59
63
|
config: options.tamaguiConfig,
|
|
@@ -145,10 +149,41 @@ async function createVscodeConfig(options) {
|
|
|
145
149
|
}
|
|
146
150
|
};
|
|
147
151
|
}
|
|
152
|
+
/** Correct the webview dist path baked into the extension-host bundle.
|
|
153
|
+
*
|
|
154
|
+
* @tomjs/vite-plugin-vscode computes `VITE_WEBVIEW_DIST` (the segment its
|
|
155
|
+
* runtime joins onto `context.extensionUri` to form the webview base URI)
|
|
156
|
+
* by stripping `process.cwd()` off the resolved outDir. That model assumes
|
|
157
|
+
* the extension is packaged from the vite project root; with an
|
|
158
|
+
* out-of-tree staging dir (ours: apps/<name>/dist-vscode + generated
|
|
159
|
+
* manifest) the strip misses and the BUILD MACHINE'S ABSOLUTE PATH gets
|
|
160
|
+
* baked into the bundle — at runtime the webview base URI doubles into
|
|
161
|
+
* `…/dist-vscode/Users/…/dist-vscode/webview` and every asset 404s.
|
|
162
|
+
*
|
|
163
|
+
* In the staging layout the correct value is always the literal
|
|
164
|
+
* `"webview"` (the assets dir next to the generated package.json), so the
|
|
165
|
+
* staging step rewrites the joinPath call site — anchored on the
|
|
166
|
+
* `.extensionUri` property read, which survives minification. */
|
|
167
|
+
async function fixStagedWebviewAssetUris(stagingDir) {
|
|
168
|
+
const bundles = ["extension/index.js", "extension/index.cjs"].map((file) => path.join(stagingDir, file));
|
|
169
|
+
let fixed = false;
|
|
170
|
+
for (const bundle of bundles) {
|
|
171
|
+
if (!fs.existsSync(bundle)) continue;
|
|
172
|
+
const source = await fs.promises.readFile(bundle, "utf-8");
|
|
173
|
+
const rewritten = source.replace(/joinPath\(([A-Za-z_$][\w$]*\.extensionUri),\s*("[^"\n]*"|'[^'\n]*'|`[^`\n]*`)\)/g, "joinPath($1, \"webview\")");
|
|
174
|
+
if (rewritten !== source) {
|
|
175
|
+
await fs.promises.writeFile(bundle, rewritten, "utf-8");
|
|
176
|
+
fixed = true;
|
|
177
|
+
}
|
|
178
|
+
}
|
|
179
|
+
return fixed;
|
|
180
|
+
}
|
|
148
181
|
/** Write the extension-manifest package.json into the staging dir. A VS
|
|
149
182
|
* Code extension's package.json IS its manifest — the product app's own
|
|
150
183
|
* package.json (an Expo/One app manifest) can't double as it, so `vsce
|
|
151
|
-
* package` runs against the staging dir instead.
|
|
184
|
+
* package` runs against the staging dir instead. Also applies
|
|
185
|
+
* `fixStagedWebviewAssetUris` — staging is the earliest race-free point after
|
|
186
|
+
* the plugin's detached extension-host build has finished. */
|
|
152
187
|
async function writeVsceManifest(stagingDir, manifest) {
|
|
153
188
|
const { engines, main, ...rest } = manifest;
|
|
154
189
|
const packageJson = {
|
|
@@ -161,7 +196,8 @@ async function writeVsceManifest(stagingDir, manifest) {
|
|
|
161
196
|
};
|
|
162
197
|
await fs.promises.mkdir(stagingDir, { recursive: true });
|
|
163
198
|
await fs.promises.writeFile(path.join(stagingDir, "package.json"), `${JSON.stringify(packageJson, null, 2)}\n`, "utf-8");
|
|
199
|
+
await fixStagedWebviewAssetUris(stagingDir);
|
|
164
200
|
}
|
|
165
201
|
|
|
166
202
|
//#endregion
|
|
167
|
-
export { DEFAULT_WEBVIEW_CSP, createVscodeConfig, resolveSeamOneAdapter, writeVsceManifest };
|
|
203
|
+
export { DEFAULT_WEBVIEW_CSP, createVscodeConfig, fixStagedWebviewAssetUris, resolveSeamOneAdapter, writeVsceManifest };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@multiplatform.one/vite-plugin-vscode",
|
|
3
|
-
"version": "6.
|
|
3
|
+
"version": "6.7.0",
|
|
4
4
|
"description": "Vite config factory for building a VS Code extension (extension host + Tamagui webview) as a target of a multiplatform.one One app — wraps @tomjs/vite-plugin-vscode with the workspace source aliases, the one-router seam alias, React dedupe against one's vendored copy, and a vsce staging-manifest writer.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"multiplatform.one",
|
|
@@ -46,11 +46,15 @@
|
|
|
46
46
|
"access": "public"
|
|
47
47
|
},
|
|
48
48
|
"dependencies": {
|
|
49
|
-
"@
|
|
49
|
+
"@babel/core": "^7.26.0",
|
|
50
|
+
"@rolldown/plugin-babel": "^0.2.3",
|
|
51
|
+
"babel-plugin-react-compiler": "^1.0.0",
|
|
52
|
+
"@multiplatform.one/utils": "6.7.0"
|
|
50
53
|
},
|
|
51
54
|
"devDependencies": {
|
|
52
55
|
"@tamagui/vite-plugin": "2.0.0-rc.41",
|
|
53
56
|
"@tomjs/vite-plugin-vscode": "^7.1.1",
|
|
57
|
+
"@types/babel__core": "^7.20.5",
|
|
54
58
|
"@types/node": "^25.6.0",
|
|
55
59
|
"@vitejs/plugin-react": "^6.0.1",
|
|
56
60
|
"typescript": "~5.9.3",
|
|
@@ -63,7 +67,7 @@
|
|
|
63
67
|
"vite": ">=5"
|
|
64
68
|
},
|
|
65
69
|
"scripts": {
|
|
66
|
-
"typecheck": "
|
|
70
|
+
"typecheck": "tsgo --noEmit",
|
|
67
71
|
"build": "rm -rf lib types 2>/dev/null && tsc -b --emitDeclarationOnly && tsdown"
|
|
68
72
|
}
|
|
69
73
|
}
|
package/src/index.ts
CHANGED
|
@@ -29,8 +29,9 @@ import {
|
|
|
29
29
|
stubExpoTypeDeclarations,
|
|
30
30
|
workspaceSourceAliases,
|
|
31
31
|
} from "@multiplatform.one/utils/dev";
|
|
32
|
+
import babel from "@rolldown/plugin-babel";
|
|
32
33
|
import vscode from "@tomjs/vite-plugin-vscode";
|
|
33
|
-
import react from "@vitejs/plugin-react";
|
|
34
|
+
import react, { reactCompilerPreset } from "@vitejs/plugin-react";
|
|
34
35
|
import type { Alias, Plugin, UserConfig } from "vite";
|
|
35
36
|
|
|
36
37
|
/** Default CSP: the plugin's default lacks font-src/img-src and blocks
|
|
@@ -85,9 +86,20 @@ export async function createVscodeConfig(options: VscodeTargetOptions): Promise<
|
|
|
85
86
|
const workspaceRoot = options.workspaceRoot ?? lookupProjectRoot();
|
|
86
87
|
const isDev = options.isDev ?? process.env.NODE_ENV !== "production";
|
|
87
88
|
const { tamaguiPlugin } = await import("@tamagui/vite-plugin");
|
|
89
|
+
// The webview entry imports tamagui.css, but the tamagui plugin only
|
|
90
|
+
// writes outputCSS DURING the build — seed it so a fresh clone's first
|
|
91
|
+
// build doesn't die on an unresolvable import.
|
|
92
|
+
const outputCSS = path.join(options.targetDir, "tamagui.css");
|
|
93
|
+
if (!fs.existsSync(outputCSS)) {
|
|
94
|
+
fs.writeFileSync(outputCSS, "/* generated by @tamagui/vite-plugin during build */\n");
|
|
95
|
+
}
|
|
88
96
|
return {
|
|
89
97
|
root: options.targetDir,
|
|
90
|
-
|
|
98
|
+
// Always root-absolute: the vscode plugin rewrites built asset URLs as
|
|
99
|
+
// `{{baseUri}}${attr}` (string concatenation), so a "./"-relative base
|
|
100
|
+
// would produce `<baseUri>./assets/…` — a literal `webview./assets`
|
|
101
|
+
// path segment the webview resource host 404s.
|
|
102
|
+
base: "/",
|
|
91
103
|
build: {
|
|
92
104
|
outDir: options.outDir,
|
|
93
105
|
emptyOutDir: true,
|
|
@@ -106,6 +118,9 @@ export async function createVscodeConfig(options: VscodeTargetOptions): Promise<
|
|
|
106
118
|
stubExpoTypeDeclarations(),
|
|
107
119
|
oneServerOnlyBrowserStub(workspaceRoot),
|
|
108
120
|
react({ jsxRuntime: "automatic" }),
|
|
121
|
+
// Same React Compiler pass the One app runs — the webview gets the
|
|
122
|
+
// memoization for free (react 19 built-in runtime).
|
|
123
|
+
babel({ presets: [reactCompilerPreset()] }),
|
|
109
124
|
tamaguiPlugin({
|
|
110
125
|
components: lookupTamaguiModules([options.targetDir]),
|
|
111
126
|
config: options.tamaguiConfig,
|
|
@@ -213,10 +228,49 @@ export interface VsceManifest {
|
|
|
213
228
|
license?: string;
|
|
214
229
|
}
|
|
215
230
|
|
|
231
|
+
/** Correct the webview dist path baked into the extension-host bundle.
|
|
232
|
+
*
|
|
233
|
+
* @tomjs/vite-plugin-vscode computes `VITE_WEBVIEW_DIST` (the segment its
|
|
234
|
+
* runtime joins onto `context.extensionUri` to form the webview base URI)
|
|
235
|
+
* by stripping `process.cwd()` off the resolved outDir. That model assumes
|
|
236
|
+
* the extension is packaged from the vite project root; with an
|
|
237
|
+
* out-of-tree staging dir (ours: apps/<name>/dist-vscode + generated
|
|
238
|
+
* manifest) the strip misses and the BUILD MACHINE'S ABSOLUTE PATH gets
|
|
239
|
+
* baked into the bundle — at runtime the webview base URI doubles into
|
|
240
|
+
* `…/dist-vscode/Users/…/dist-vscode/webview` and every asset 404s.
|
|
241
|
+
*
|
|
242
|
+
* In the staging layout the correct value is always the literal
|
|
243
|
+
* `"webview"` (the assets dir next to the generated package.json), so the
|
|
244
|
+
* staging step rewrites the joinPath call site — anchored on the
|
|
245
|
+
* `.extensionUri` property read, which survives minification. */
|
|
246
|
+
export async function fixStagedWebviewAssetUris(stagingDir: string): Promise<boolean> {
|
|
247
|
+
const bundles = ["extension/index.js", "extension/index.cjs"].map((file) =>
|
|
248
|
+
path.join(stagingDir, file),
|
|
249
|
+
);
|
|
250
|
+
let fixed = false;
|
|
251
|
+
for (const bundle of bundles) {
|
|
252
|
+
if (!fs.existsSync(bundle)) continue;
|
|
253
|
+
const source = await fs.promises.readFile(bundle, "utf-8");
|
|
254
|
+
const rewritten = source.replace(
|
|
255
|
+
// The dist segment may be emitted as a quoted string OR a template
|
|
256
|
+
// literal (tsdown's env define does both depending on content).
|
|
257
|
+
/joinPath\(([A-Za-z_$][\w$]*\.extensionUri),\s*("[^"\n]*"|'[^'\n]*'|`[^`\n]*`)\)/g,
|
|
258
|
+
'joinPath($1, "webview")',
|
|
259
|
+
);
|
|
260
|
+
if (rewritten !== source) {
|
|
261
|
+
await fs.promises.writeFile(bundle, rewritten, "utf-8");
|
|
262
|
+
fixed = true;
|
|
263
|
+
}
|
|
264
|
+
}
|
|
265
|
+
return fixed;
|
|
266
|
+
}
|
|
267
|
+
|
|
216
268
|
/** Write the extension-manifest package.json into the staging dir. A VS
|
|
217
269
|
* Code extension's package.json IS its manifest — the product app's own
|
|
218
270
|
* package.json (an Expo/One app manifest) can't double as it, so `vsce
|
|
219
|
-
* package` runs against the staging dir instead.
|
|
271
|
+
* package` runs against the staging dir instead. Also applies
|
|
272
|
+
* `fixStagedWebviewAssetUris` — staging is the earliest race-free point after
|
|
273
|
+
* the plugin's detached extension-host build has finished. */
|
|
220
274
|
export async function writeVsceManifest(stagingDir: string, manifest: VsceManifest): Promise<void> {
|
|
221
275
|
const { engines, main, ...rest } = manifest;
|
|
222
276
|
const packageJson = {
|
|
@@ -230,4 +284,5 @@ export async function writeVsceManifest(stagingDir: string, manifest: VsceManife
|
|
|
230
284
|
`${JSON.stringify(packageJson, null, 2)}\n`,
|
|
231
285
|
"utf-8",
|
|
232
286
|
);
|
|
287
|
+
await fixStagedWebviewAssetUris(stagingDir);
|
|
233
288
|
}
|
package/types/index.d.ts
CHANGED
|
@@ -49,9 +49,27 @@ export interface VsceManifest {
|
|
|
49
49
|
repository?: unknown;
|
|
50
50
|
license?: string;
|
|
51
51
|
}
|
|
52
|
+
/** Correct the webview dist path baked into the extension-host bundle.
|
|
53
|
+
*
|
|
54
|
+
* @tomjs/vite-plugin-vscode computes `VITE_WEBVIEW_DIST` (the segment its
|
|
55
|
+
* runtime joins onto `context.extensionUri` to form the webview base URI)
|
|
56
|
+
* by stripping `process.cwd()` off the resolved outDir. That model assumes
|
|
57
|
+
* the extension is packaged from the vite project root; with an
|
|
58
|
+
* out-of-tree staging dir (ours: apps/<name>/dist-vscode + generated
|
|
59
|
+
* manifest) the strip misses and the BUILD MACHINE'S ABSOLUTE PATH gets
|
|
60
|
+
* baked into the bundle — at runtime the webview base URI doubles into
|
|
61
|
+
* `…/dist-vscode/Users/…/dist-vscode/webview` and every asset 404s.
|
|
62
|
+
*
|
|
63
|
+
* In the staging layout the correct value is always the literal
|
|
64
|
+
* `"webview"` (the assets dir next to the generated package.json), so the
|
|
65
|
+
* staging step rewrites the joinPath call site — anchored on the
|
|
66
|
+
* `.extensionUri` property read, which survives minification. */
|
|
67
|
+
export declare function fixStagedWebviewAssetUris(stagingDir: string): Promise<boolean>;
|
|
52
68
|
/** Write the extension-manifest package.json into the staging dir. A VS
|
|
53
69
|
* Code extension's package.json IS its manifest — the product app's own
|
|
54
70
|
* package.json (an Expo/One app manifest) can't double as it, so `vsce
|
|
55
|
-
* package` runs against the staging dir instead.
|
|
71
|
+
* package` runs against the staging dir instead. Also applies
|
|
72
|
+
* `fixStagedWebviewAssetUris` — staging is the earliest race-free point after
|
|
73
|
+
* the plugin's detached extension-host build has finished. */
|
|
56
74
|
export declare function writeVsceManifest(stagingDir: string, manifest: VsceManifest): Promise<void>;
|
|
57
75
|
//# sourceMappingURL=index.d.ts.map
|
package/types/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAkCA,OAAO,KAAK,EAAE,KAAK,EAAU,UAAU,EAAE,MAAM,MAAM,CAAC;AAEtD;;;0CAG0C;AAC1C,eAAO,MAAM,mBAAmB,yRAAqR,CAAC;AAEtT,MAAM,WAAW,mBAAmB;IAClC;kCAC8B;IAC9B,SAAS,EAAE,MAAM,CAAC;IAClB;kEAC8D;IAC9D,MAAM,EAAE,MAAM,CAAC;IACf,qEAAqE;IACrE,aAAa,EAAE,MAAM,CAAC;IACtB,qDAAqD;IACrD,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,0DAA0D;IAC1D,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,sDAAsD;IACtD,MAAM,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACjC,0DAA0D;IAC1D,OAAO,CAAC,EAAE,KAAK,EAAE,CAAC;CACnB;AAgBD;kEACkE;AAClE,wBAAgB,qBAAqB,CAAC,aAAa,EAAE,MAAM,GAAG,MAAM,CAInE;AAED,wBAAsB,kBAAkB,CAAC,OAAO,EAAE,mBAAmB,GAAG,OAAO,CAAC,UAAU,CAAC,CA0H1F;AAID,MAAM,WAAW,YAAY;IAC3B,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,EAAE,MAAM,CAAC;IAChB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,sEAAsE;IACtE,IAAI,CAAC,EAAE,QAAQ,GAAG,UAAU,CAAC;IAC7B,2CAA2C;IAC3C,OAAO,CAAC,EAAE;QAAE,MAAM,EAAE,MAAM,CAAC;QAAC,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAC;IACpD,6DAA6D;IAC7D,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,WAAW,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACtC,gBAAgB,CAAC,EAAE,MAAM,EAAE,CAAC;IAC5B,UAAU,CAAC,EAAE,MAAM,EAAE,CAAC;IACtB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAED;;;;;;;;;;;;;;kEAckE;AAClE,wBAAsB,yBAAyB,CAAC,UAAU,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC,CAoBpF;AAED;;;;;+DAK+D;AAC/D,wBAAsB,iBAAiB,CAAC,UAAU,EAAE,MAAM,EAAE,QAAQ,EAAE,YAAY,GAAG,OAAO,CAAC,IAAI,CAAC,CAcjG"}
|