@afterpack/wasm 0.2.6 → 0.2.7
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/dist/api.js +3 -0
- package/dist/version.d.ts +1 -0
- package/dist/version.js +1 -0
- package/engine/afterpack_engine_bg.wasm +0 -0
- package/package.json +1 -1
- package/readme.md +2 -2
package/dist/api.js
CHANGED
|
@@ -2,6 +2,7 @@ import { cloudApiBase } from "./cloud-base.js";
|
|
|
2
2
|
import { ObfuscationError } from "./contract.js";
|
|
3
3
|
import { engineCrash } from "./crash.js";
|
|
4
4
|
import { engineVersion, processFile, randomSeed } from "./engine.js";
|
|
5
|
+
import { PACKAGE_VERSION } from "./version.js";
|
|
5
6
|
export * from "./contract.js";
|
|
6
7
|
const decoder = new TextDecoder();
|
|
7
8
|
const encoder = new TextEncoder();
|
|
@@ -216,6 +217,8 @@ async function requestCloudBatch(key, form) {
|
|
|
216
217
|
method: "POST",
|
|
217
218
|
headers: {
|
|
218
219
|
Authorization: `Bearer ${key}`,
|
|
220
|
+
"X-AfterPack-Client-Version": PACKAGE_VERSION,
|
|
221
|
+
"X-AfterPack-Client": `@afterpack/wasm/${PACKAGE_VERSION}`,
|
|
219
222
|
"X-AfterPack-Client-Timeout-Ms": String(REQUEST_TIMEOUT_MS),
|
|
220
223
|
},
|
|
221
224
|
body: form,
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const PACKAGE_VERSION = "0.2.7-rc.202610170324";
|
package/dist/version.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const PACKAGE_VERSION = "0.2.7-rc.202610170324";
|
|
Binary file
|
package/package.json
CHANGED
package/readme.md
CHANGED
|
@@ -75,8 +75,8 @@ Without a key, all of Free runs inside your Worker or Node process, with every p
|
|
|
75
75
|
|
|
76
76
|
| Measure | Bytes | |
|
|
77
77
|
|---|---:|---|
|
|
78
|
-
| Raw `.wasm` | 4,569,
|
|
79
|
-
| Gzipped | 1,306,
|
|
78
|
+
| Raw `.wasm` | 4,569,276 | 4.36 MiB |
|
|
79
|
+
| Gzipped | 1,306,517 | 1.25 MiB |
|
|
80
80
|
|
|
81
81
|
This fits Cloudflare's Worker size limit on both the free and paid plans. CPU time is the tighter limit: the free plan allows 10 ms per request, and obfuscating a 185 KB bundle at `complexity: 8` takes about 263 ms on an Apple M-series laptop. Plan on Workers Paid for real bundles.
|
|
82
82
|
|