From 115680fa0a66c7d40df72a613041e3ef86f2d73a Mon Sep 17 00:00:00 2001 From: syumai Date: Wed, 3 Jan 2024 23:27:31 +0900 Subject: [PATCH] fix sockets example --- _examples/sockets/Makefile | 2 +- _examples/sockets/README.md | 6 +++--- _examples/sockets/go.mod | 2 +- _examples/sockets/go.sum | 2 -- 4 files changed, 5 insertions(+), 7 deletions(-) diff --git a/_examples/sockets/Makefile b/_examples/sockets/Makefile index 171f487..3140ac9 100644 --- a/_examples/sockets/Makefile +++ b/_examples/sockets/Makefile @@ -4,7 +4,7 @@ dev: .PHONY: build build: - go run ../../cmd/workers-assets-gen --mode go + go run ../../cmd/workers-assets-gen -mode=go GOOS=js GOARCH=wasm go build -o ./build/app.wasm . .PHONY: deploy diff --git a/_examples/sockets/README.md b/_examples/sockets/README.md index 5928625..8e6603f 100644 --- a/_examples/sockets/README.md +++ b/_examples/sockets/README.md @@ -1,6 +1,6 @@ # sockets -- makes a TCP connection to tcpbin.com:4242. +- makes a TCP connection to tcpbin.com:4242 and sends message. ## Development @@ -14,7 +14,7 @@ This project requires these tools to be installed globally. ### Commands ``` -make dev # run dev server -make build # build Go Wasm binary +make dev # run dev server +make build # build Go Wasm binary make deploy # deploy worker ``` diff --git a/_examples/sockets/go.mod b/_examples/sockets/go.mod index 6ec9028..bbd32de 100644 --- a/_examples/sockets/go.mod +++ b/_examples/sockets/go.mod @@ -1,4 +1,4 @@ -module github.com/syumai/workers/_examples/fetch +module github.com/syumai/workers/_examples/sockets go 1.21.3 diff --git a/_examples/sockets/go.sum b/_examples/sockets/go.sum index 8c27871..e69de29 100644 --- a/_examples/sockets/go.sum +++ b/_examples/sockets/go.sum @@ -1,2 +0,0 @@ -github.com/syumai/workers v0.1.0 h1:z5QfQR2X+PCKzom7RodpI5J4D5YF7NT7Qwzb9AM9dgY= -github.com/syumai/workers v0.1.0/go.mod h1:alXIDhTyeTwSzh0ZgQ3cb9HQPyyYfIejupE4Z3efr14=