From 643bb9797715af4f6199aaa9d083721b560c2628 Mon Sep 17 00:00:00 2001 From: Evan Su <48808396+HACKERALERT@users.noreply.github.com> Date: Thu, 4 Jan 2024 15:02:16 -0500 Subject: [PATCH] Add detail to compiling for web --- web/README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/web/README.md b/web/README.md index 9b5f091..db3cad1 100644 --- a/web/README.md +++ b/web/README.md @@ -4,3 +4,5 @@ To build the web interface from source, you will need to compile the Go code int GOOS=js GOARCH=wasm go build -ldflags="-s -w" index.go ``` This will create a binary file. Compress it with [LZMA](https://github.com/LZMA-JS/LZMA-JS), encode it in Base64, and paste the final result to [L198](https://github.com/HACKERALERT/Picocrypt/blob/main/web/index.html#L198). + +You'll also need to update [`wasm_exec.js`](https://cdn.jsdelivr.net/gh/golang/go@go1.21.5/misc/wasm/wasm_exec.min.js) (replace the Go version accordingly) on [L197](https://github.com/HACKERALERT/Picocrypt/blob/main/web/index.html#L197) to glue everything together.