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

No web items in eframe doc (docs.rs) #3756

Closed
morionelab opened this issue Dec 31, 2023 · 0 comments · Fixed by #3757
Closed

No web items in eframe doc (docs.rs) #3756

morionelab opened this issue Dec 31, 2023 · 0 comments · Fixed by #3757

Comments

@morionelab
Copy link

Currently, the platform list of eframe doc (docs.rs/eframe/0.24.1) contains only

  • x86_64-unknown-linux-gnu

and web items for wasm32-unknown-unknown (e.g. WebRunner) aren't accessible.

I've found docs.rs/eframe/0.21.3 has wasm32-unknown-unknown in the platform list, while 0.22 and later does not.

I'm not sure (no way to verify), but modifying eframe/Cargo.toml as follows may solve this issue (see also docs.rs metadata)

  [package.metadata.docs.rs]
  all-features = true
  targets = ["x86_64-unknown-linux-gnu", "wasm32-unknown-unknown"]
+ rustc-args = ["--cfg=web_sys_unstable_apis"]

because

  • Since 0.22 removed the feature webgl from the dependency wgpu, eframe requires the flag --cfg=web_sys_unstable_apis to build for wasm32-unknown-unknown (with all features).

  • .cargo/config.toml in the parent path seems missed by docs.rs as it fetches and processes each crate separately.

Note that docs.rs seems to ignore errors of the non-first targets silently and just drop the erroneous ones from the platform list.

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 a pull request may close this issue.

1 participant