Skip to content
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. #16

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

Add WebAssembly support. #16

wants to merge 2 commits into from

Conversation

dmitshur
Copy link
Member

@dmitshur dmitshur commented Nov 4, 2018

This change is a work in progress on adding support for WebAssembly to package glfw, 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
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant