Skip to content

Add WASM Support #77

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

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

Add WASM Support #77

wants to merge 10 commits into from

Conversation

jonaspleyer
Copy link

This PR makes the crates_io_api package able to be used in a WASM context. Some functionality such as std::time needed to be replaced with the web_time crate which exports std::time for non-wasm systems (such as x86). In total this PR does 3 things:

  1. Refactor Code; exlude shared functionality in utils.rs
  2. Loosen and Update Dependencies
  3. Rewrite async_client.rs file such that it can be compiled with the wasm32-unknown-unknown target triple.

All tests are still passing. Users which have used this package should not be affected by any of the changes made. Let me know what you think.

@jonaspleyer
Copy link
Author

Note that the most recent commits are part of an effort to have an intermediate package which can be used for publishing to crates.io.

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