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

Building on top of wasm-bindgen? #318

Closed
alexcrichton opened this Issue Jan 10, 2019 · 10 comments

Comments

Projects
None yet
6 participants
@alexcrichton
Copy link

alexcrichton commented Jan 10, 2019

This topic has come up from time to time, but I'd be curious if it'd be good to make this official? Would stdweb be up for officially moving in the direction (eventually) of building on top of wasm-bindgen?

If so, I'd be more than willing to help fill out more information and work with y'all to make sure we can handle everything. We mentioned during the last rustwasm working group meeting that I'd meet with @Pauan and have some discussion on Discord, but I wasn't able to reach them just afterwards :(. In any case, if this sounds like a good idea, it's probably best to close this an open a more official tracking issue next.

@Pauan

This comment has been minimized.

Copy link
Contributor

Pauan commented Jan 13, 2019

(I was able to get Discord working, so that's not a problem anymore)

@TitanThinktank

This comment has been minimized.

Copy link

TitanThinktank commented Jan 22, 2019

Lets hope cargo web dont get infected by node npm or webpack, it was a hell in wasm bingen to get around it, now i am counting on stdweb for true web programming in Rust.

@koute

This comment has been minimized.

Copy link
Owner

koute commented Jan 24, 2019

I apologize for the late reply; I was completely away for the last two weeks.

This topic has come up from time to time, but I'd be curious if it'd be good to make this official? Would stdweb be up for officially moving in the direction (eventually) of building on top of wasm-bindgen?

Yes! I'll try to catch up on the recent discussions and try to push something forward from our side.

Lets hope cargo web dont get infected by node npm or webpack, it was a hell in wasm bingen to get around it, now i am counting on stdweb for true web programming in Rust.

You might be slightly overexaggerating, but don't worry. (: I intend to keep the current cargo-web workflow for those people who currently want to keep using it. (This also includes Emscripten compatibility where I do intend to keep stdweb compatible with Emscripten as there are people who use/want that.)

No loss of functionality is planned, just extra compatibility with wasm-bindgen.

@Pauan Pauan referenced this issue Jan 29, 2019

Merged

2019 roadmap #7

@luover

This comment has been minimized.

Copy link

luover commented Feb 26, 2019

@newpavlov

This comment has been minimized.

Copy link

newpavlov commented Mar 19, 2019

Any updates on this? It would be nice to remove stdweb feature in getrandom.

@koute

This comment has been minimized.

Copy link
Owner

koute commented Apr 7, 2019

I've just added initial support for wasm-bindgen on master; see this for a working example. It's still not fully working though, mainly due to this issue:

rustwasm/wasm-bindgen#1427

@newpavlov Even though stdweb will be compatible with wasm-bindgen there are still people who do not use wasm-bindgen. Some people use Emscripten (which stdweb fully supports), and some people target wasm32-unknown-unknown through cargo-web (so without going through wasm-bindgen). It's of course completely up to you if you want to support those.

@alexcrichton

This comment has been minimized.

Copy link
Author

alexcrichton commented Apr 8, 2019

Great news! Thanks for pushing on this @koute!

Feel free to ping us or open issues for anything missing as usual, and sorry for not implementing the function table sooner, that was a mixup for sure!

@koute

This comment has been minimized.

Copy link
Owner

koute commented Apr 14, 2019

@alexcrichton Thanks for the swift response!

Okay, in theory everything should work now on the current master! Unfortunately I still haven't ran the test suite under wasm-bindgen due to rustwasm/wasm-bindgen#1458, so I can't guarantee that everything isn't actually horribly broken. (: It'd be nice to get that sorted out, or at least figure out some sort of a temporary workaround.

I've also made wasm-bindgen the default when not using cargo-web, so it should work out-of-box without having to enable any extra features.

@alexcrichton

This comment has been minimized.

Copy link
Author

alexcrichton commented Apr 15, 2019

Okay, in theory everything should work now on the current master!

Nice!

It'd be nice to get that sorted out, or at least figure out some sort of a temporary workaround.

Definitely! I've commented on the issue and I think we can make good progress soon on it

I've also made wasm-bindgen the default when not using cargo-web, so it should work out-of-box without having to enable any extra features.

Also nice! Thanks again so much for all your work on this!

I think this is basically all implemented now, so closing.

@koute

This comment has been minimized.

Copy link
Owner

koute commented Apr 15, 2019

Released as 0.4.16!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.