New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add WebAssembly support. #27

Open
wants to merge 2 commits into
base: master
from

Conversation

Projects
None yet
1 participant
@dmitshur
Member

dmitshur commented Nov 4, 2018

This change is a work in progress on adding support for WebAssembly to package gl, while maintaining GopherJS support.

It's done by differentiating code for WebAssembly (which uses syscall/js API) from existing code for GopherJS (which uses github.com/gopherjs/gopherjs/js API) with the following build constraints:

_js.go

// +build js,!wasm

... GopherJS code ...

_wasm.go

// +build js,wasm

... WebAssembly code ...

It has been developed and tested primarily with the Hover and eX0-go projects.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment