You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+6-5Lines changed: 6 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -16,6 +16,7 @@ GopherJS compiles Go code ([golang.org](https://golang.org/)) to pure JavaScript
16
16
17
17
### What's new?
18
18
19
+
- 2022-XX-XX: Go 1.18 support is available
19
20
- 2021-09-19: Go 1.17 support is available!
20
21
- 2021-08-23: Go Modules are now fully supported.
21
22
- 2021-06-19: Complete `syscall/js` package implementation compatible with the upstream Go 1.16.
@@ -31,7 +32,7 @@ Nearly everything, including Goroutines ([compatibility documentation](https://g
31
32
32
33
### Installation and Usage
33
34
34
-
GopherJS [requires Go 1.17 or newer](https://github.com/gopherjs/gopherjs/blob/master/doc/compatibility.md#go-version-compatibility). If you need an older Go
35
+
GopherJS [requires Go 1.18 or newer](https://github.com/gopherjs/gopherjs/blob/master/doc/compatibility.md#go-version-compatibility). If you need an older Go
35
36
version, you can use an [older Gopher release](https://github.com/gopherjs/gopherjs/releases).
36
37
37
38
Get or update GopherJS and dependencies with:
@@ -40,12 +41,12 @@ Get or update GopherJS and dependencies with:
40
41
go get -u github.com/gopherjs/gopherjs
41
42
```
42
43
43
-
If your local Go distribution as reported by `go version` is newer than Go 1.17, then you need to set the `GOPHERJS_GOROOT` environment variable to a directory that contains a Go 1.17 distribution. For example:
44
+
If your local Go distribution as reported by `go version` is newer than Go 1.18, then you need to set the `GOPHERJS_GOROOT` environment variable to a directory that contains a Go 1.18 distribution. For example:
44
45
45
46
```
46
-
go get golang.org/dl/go1.17.1
47
-
go1.17.1 download
48
-
export GOPHERJS_GOROOT="$(go1.17.1 env GOROOT)" # Also add this line to your .profile or equivalent.
47
+
go get golang.org/dl/go1.18.1
48
+
go1.18.1 download
49
+
export GOPHERJS_GOROOT="$(go1.18.1 env GOROOT)" # Also add this line to your .profile or equivalent.
49
50
```
50
51
51
52
Now you can use `gopherjs build [package]`, `gopherjs build [files]` or `gopherjs install [package]` which behave similar to the `go` tool. For `main` packages, these commands create a `.js` file and `.js.map` source map in the current directory or in `$GOPATH/bin`. The generated JavaScript file can be used as usual in a website. Use `gopherjs help [command]` to get a list of possible command line flags, e.g. for minification and automatically watching for changes.
0 commit comments