esbuild 0.15.16 → 0.15.18
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/bin/esbuild +1 -1
- package/install.js +4 -4
- package/lib/main.d.ts +1 -1
- package/lib/main.js +10 -9
- package/package.json +23 -23
package/bin/esbuild
CHANGED
|
@@ -190,7 +190,7 @@ for your current platform.`);
|
|
|
190
190
|
"node_modules",
|
|
191
191
|
".cache",
|
|
192
192
|
"esbuild",
|
|
193
|
-
`pnpapi-${pkg}-${"0.15.
|
|
193
|
+
`pnpapi-${pkg}-${"0.15.18"}-${path.basename(subpath)}`
|
|
194
194
|
);
|
|
195
195
|
if (!fs.existsSync(binTargetPath)) {
|
|
196
196
|
fs.mkdirSync(path.dirname(binTargetPath), { recursive: true });
|
package/install.js
CHANGED
|
@@ -90,8 +90,8 @@ function validateBinaryVersion(...command) {
|
|
|
90
90
|
const stdout = child_process.execFileSync(command.shift(), command, {
|
|
91
91
|
stdio: "pipe"
|
|
92
92
|
}).toString().trim();
|
|
93
|
-
if (stdout !== "0.15.
|
|
94
|
-
throw new Error(`Expected ${JSON.stringify("0.15.
|
|
93
|
+
if (stdout !== "0.15.18") {
|
|
94
|
+
throw new Error(`Expected ${JSON.stringify("0.15.18")} but got ${JSON.stringify(stdout)}`);
|
|
95
95
|
}
|
|
96
96
|
}
|
|
97
97
|
function isYarn() {
|
|
@@ -143,7 +143,7 @@ function installUsingNPM(pkg, subpath, binPath) {
|
|
|
143
143
|
try {
|
|
144
144
|
fs2.writeFileSync(path2.join(installDir, "package.json"), "{}");
|
|
145
145
|
child_process.execSync(
|
|
146
|
-
`npm install --loglevel=error --prefer-offline --no-audit --progress=false ${pkg}@${"0.15.
|
|
146
|
+
`npm install --loglevel=error --prefer-offline --no-audit --progress=false ${pkg}@${"0.15.18"}`,
|
|
147
147
|
{ cwd: installDir, stdio: "pipe", env }
|
|
148
148
|
);
|
|
149
149
|
const installedBinPath = path2.join(installDir, "node_modules", pkg, subpath);
|
|
@@ -194,7 +194,7 @@ function maybeOptimizePackage(binPath) {
|
|
|
194
194
|
}
|
|
195
195
|
}
|
|
196
196
|
async function downloadDirectlyFromNPM(pkg, subpath, binPath) {
|
|
197
|
-
const url = `https://registry.npmjs.org/${pkg}/-/${pkg}-${"0.15.
|
|
197
|
+
const url = `https://registry.npmjs.org/${pkg}/-/${pkg}-${"0.15.18"}.tgz`;
|
|
198
198
|
console.error(`[esbuild] Trying to download ${JSON.stringify(url)}`);
|
|
199
199
|
try {
|
|
200
200
|
fs2.writeFileSync(binPath, extractFileFromTarGzip(await fetch(url), subpath));
|
package/lib/main.d.ts
CHANGED
|
@@ -588,7 +588,7 @@ export interface InitializeOptions {
|
|
|
588
588
|
* The URL of the "esbuild.wasm" file. This must be provided when running
|
|
589
589
|
* esbuild in the browser.
|
|
590
590
|
*/
|
|
591
|
-
wasmURL?: string
|
|
591
|
+
wasmURL?: string | URL
|
|
592
592
|
|
|
593
593
|
/**
|
|
594
594
|
* The result of calling "new WebAssembly.Module(buffer)" where "buffer"
|
package/lib/main.js
CHANGED
|
@@ -230,6 +230,7 @@ var mustBeStringOrBoolean = (value) => typeof value === "string" || typeof value
|
|
|
230
230
|
var mustBeStringOrObject = (value) => typeof value === "string" || typeof value === "object" && value !== null && !Array.isArray(value) ? null : "a string or an object";
|
|
231
231
|
var mustBeStringOrArray = (value) => typeof value === "string" || Array.isArray(value) ? null : "a string or an array";
|
|
232
232
|
var mustBeStringOrUint8Array = (value) => typeof value === "string" || value instanceof Uint8Array ? null : "a string or a Uint8Array";
|
|
233
|
+
var mustBeStringOrURL = (value) => typeof value === "string" || value instanceof URL ? null : "a string or a URL";
|
|
233
234
|
function getFlag(object, keys, key, mustBeFn) {
|
|
234
235
|
let value = object[key];
|
|
235
236
|
keys[key + ""] = true;
|
|
@@ -249,7 +250,7 @@ function checkForInvalidFlags(object, keys, where) {
|
|
|
249
250
|
}
|
|
250
251
|
function validateInitializeOptions(options) {
|
|
251
252
|
let keys = /* @__PURE__ */ Object.create(null);
|
|
252
|
-
let wasmURL = getFlag(options, keys, "wasmURL",
|
|
253
|
+
let wasmURL = getFlag(options, keys, "wasmURL", mustBeStringOrURL);
|
|
253
254
|
let wasmModule = getFlag(options, keys, "wasmModule", mustBeWebAssemblyModule);
|
|
254
255
|
let worker = getFlag(options, keys, "worker", mustBeBoolean);
|
|
255
256
|
checkForInvalidFlags(options, keys, "in initialize() call");
|
|
@@ -717,8 +718,8 @@ function createChannel(streamIn) {
|
|
|
717
718
|
if (isFirstPacket) {
|
|
718
719
|
isFirstPacket = false;
|
|
719
720
|
let binaryVersion = String.fromCharCode(...bytes);
|
|
720
|
-
if (binaryVersion !== "0.15.
|
|
721
|
-
throw new Error(`Cannot start service: Host version "${"0.15.
|
|
721
|
+
if (binaryVersion !== "0.15.18") {
|
|
722
|
+
throw new Error(`Cannot start service: Host version "${"0.15.18"}" does not match binary version ${JSON.stringify(binaryVersion)}`);
|
|
722
723
|
}
|
|
723
724
|
return;
|
|
724
725
|
}
|
|
@@ -1838,7 +1839,7 @@ for your current platform.`);
|
|
|
1838
1839
|
"node_modules",
|
|
1839
1840
|
".cache",
|
|
1840
1841
|
"esbuild",
|
|
1841
|
-
`pnpapi-${pkg}-${"0.15.
|
|
1842
|
+
`pnpapi-${pkg}-${"0.15.18"}-${path.basename(subpath)}`
|
|
1842
1843
|
);
|
|
1843
1844
|
if (!fs.existsSync(binTargetPath)) {
|
|
1844
1845
|
fs.mkdirSync(path.dirname(binTargetPath), { recursive: true });
|
|
@@ -1870,7 +1871,7 @@ if (process.env.ESBUILD_WORKER_THREADS !== "0") {
|
|
|
1870
1871
|
}
|
|
1871
1872
|
}
|
|
1872
1873
|
var _a;
|
|
1873
|
-
var isInternalWorkerThread = ((_a = worker_threads == null ? void 0 : worker_threads.workerData) == null ? void 0 : _a.esbuildVersion) === "0.15.
|
|
1874
|
+
var isInternalWorkerThread = ((_a = worker_threads == null ? void 0 : worker_threads.workerData) == null ? void 0 : _a.esbuildVersion) === "0.15.18";
|
|
1874
1875
|
var esbuildCommandAndArgs = () => {
|
|
1875
1876
|
if ((!ESBUILD_BINARY_PATH || false) && (path2.basename(__filename) !== "main.js" || path2.basename(__dirname) !== "lib")) {
|
|
1876
1877
|
throw new Error(
|
|
@@ -1937,7 +1938,7 @@ var fsAsync = {
|
|
|
1937
1938
|
}
|
|
1938
1939
|
}
|
|
1939
1940
|
};
|
|
1940
|
-
var version = "0.15.
|
|
1941
|
+
var version = "0.15.18";
|
|
1941
1942
|
var build = (options) => ensureServiceIsRunning().build(options);
|
|
1942
1943
|
var serve = (serveOptions, buildOptions) => ensureServiceIsRunning().serve(serveOptions, buildOptions);
|
|
1943
1944
|
var transform = (input, options) => ensureServiceIsRunning().transform(input, options);
|
|
@@ -2048,7 +2049,7 @@ var ensureServiceIsRunning = () => {
|
|
|
2048
2049
|
if (longLivedService)
|
|
2049
2050
|
return longLivedService;
|
|
2050
2051
|
let [command, args] = esbuildCommandAndArgs();
|
|
2051
|
-
let child = child_process.spawn(command, args.concat(`--service=${"0.15.
|
|
2052
|
+
let child = child_process.spawn(command, args.concat(`--service=${"0.15.18"}`, "--ping"), {
|
|
2052
2053
|
windowsHide: true,
|
|
2053
2054
|
stdio: ["pipe", "pipe", "inherit"],
|
|
2054
2055
|
cwd: defaultWD
|
|
@@ -2162,7 +2163,7 @@ var runServiceSync = (callback) => {
|
|
|
2162
2163
|
esbuild: node_exports
|
|
2163
2164
|
});
|
|
2164
2165
|
callback(service);
|
|
2165
|
-
let stdout = child_process.execFileSync(command, args.concat(`--service=${"0.15.
|
|
2166
|
+
let stdout = child_process.execFileSync(command, args.concat(`--service=${"0.15.18"}`), {
|
|
2166
2167
|
cwd: defaultWD,
|
|
2167
2168
|
windowsHide: true,
|
|
2168
2169
|
input: stdin,
|
|
@@ -2178,7 +2179,7 @@ var workerThreadService = null;
|
|
|
2178
2179
|
var startWorkerThreadService = (worker_threads2) => {
|
|
2179
2180
|
let { port1: mainPort, port2: workerPort } = new worker_threads2.MessageChannel();
|
|
2180
2181
|
let worker = new worker_threads2.Worker(__filename, {
|
|
2181
|
-
workerData: { workerPort, defaultWD, esbuildVersion: "0.15.
|
|
2182
|
+
workerData: { workerPort, defaultWD, esbuildVersion: "0.15.18" },
|
|
2182
2183
|
transferList: [workerPort],
|
|
2183
2184
|
execArgv: []
|
|
2184
2185
|
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "esbuild",
|
|
3
|
-
"version": "0.15.
|
|
3
|
+
"version": "0.15.18",
|
|
4
4
|
"description": "An extremely fast JavaScript and CSS bundler and minifier.",
|
|
5
5
|
"repository": "https://github.com/evanw/esbuild",
|
|
6
6
|
"scripts": {
|
|
@@ -15,28 +15,28 @@
|
|
|
15
15
|
"esbuild": "bin/esbuild"
|
|
16
16
|
},
|
|
17
17
|
"optionalDependencies": {
|
|
18
|
-
"@esbuild/android-arm": "0.15.
|
|
19
|
-
"@esbuild/linux-loong64": "0.15.
|
|
20
|
-
"esbuild-android-64": "0.15.
|
|
21
|
-
"esbuild-android-arm64": "0.15.
|
|
22
|
-
"esbuild-darwin-64": "0.15.
|
|
23
|
-
"esbuild-darwin-arm64": "0.15.
|
|
24
|
-
"esbuild-freebsd-64": "0.15.
|
|
25
|
-
"esbuild-freebsd-arm64": "0.15.
|
|
26
|
-
"esbuild-linux-32": "0.15.
|
|
27
|
-
"esbuild-linux-64": "0.15.
|
|
28
|
-
"esbuild-linux-arm": "0.15.
|
|
29
|
-
"esbuild-linux-arm64": "0.15.
|
|
30
|
-
"esbuild-linux-mips64le": "0.15.
|
|
31
|
-
"esbuild-linux-ppc64le": "0.15.
|
|
32
|
-
"esbuild-linux-riscv64": "0.15.
|
|
33
|
-
"esbuild-linux-s390x": "0.15.
|
|
34
|
-
"esbuild-netbsd-64": "0.15.
|
|
35
|
-
"esbuild-openbsd-64": "0.15.
|
|
36
|
-
"esbuild-sunos-64": "0.15.
|
|
37
|
-
"esbuild-windows-32": "0.15.
|
|
38
|
-
"esbuild-windows-64": "0.15.
|
|
39
|
-
"esbuild-windows-arm64": "0.15.
|
|
18
|
+
"@esbuild/android-arm": "0.15.18",
|
|
19
|
+
"@esbuild/linux-loong64": "0.15.18",
|
|
20
|
+
"esbuild-android-64": "0.15.18",
|
|
21
|
+
"esbuild-android-arm64": "0.15.18",
|
|
22
|
+
"esbuild-darwin-64": "0.15.18",
|
|
23
|
+
"esbuild-darwin-arm64": "0.15.18",
|
|
24
|
+
"esbuild-freebsd-64": "0.15.18",
|
|
25
|
+
"esbuild-freebsd-arm64": "0.15.18",
|
|
26
|
+
"esbuild-linux-32": "0.15.18",
|
|
27
|
+
"esbuild-linux-64": "0.15.18",
|
|
28
|
+
"esbuild-linux-arm": "0.15.18",
|
|
29
|
+
"esbuild-linux-arm64": "0.15.18",
|
|
30
|
+
"esbuild-linux-mips64le": "0.15.18",
|
|
31
|
+
"esbuild-linux-ppc64le": "0.15.18",
|
|
32
|
+
"esbuild-linux-riscv64": "0.15.18",
|
|
33
|
+
"esbuild-linux-s390x": "0.15.18",
|
|
34
|
+
"esbuild-netbsd-64": "0.15.18",
|
|
35
|
+
"esbuild-openbsd-64": "0.15.18",
|
|
36
|
+
"esbuild-sunos-64": "0.15.18",
|
|
37
|
+
"esbuild-windows-32": "0.15.18",
|
|
38
|
+
"esbuild-windows-64": "0.15.18",
|
|
39
|
+
"esbuild-windows-arm64": "0.15.18"
|
|
40
40
|
},
|
|
41
41
|
"license": "MIT"
|
|
42
42
|
}
|