Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Purpose
This PR equips web-sys with an updated WebGPU.webidl (and related interfaces).
The current WebGPU bindings provided by web-sys are severely outdated and should be brought closer into alignment with the draft spec.
Implications
The bindings are working well for me the development of a handful of games and apps and whilst I have not encountered issues using the changes present in this PR, these changes impact the Window and Navigator interfaces and as such are breaking.
Process
This was only ever merely an artefact of Mozilla's incomplete implementation.
WebGPU now exists on the navigator interface as
.gpu
This dump is then stitched into wasm-bindgen/creates/web-sys/Cargo.toml
Caveats
I'm not certain the following unintended changes are inert. The eventual merger of this PR should ensure they're not impactful.
I chose not to continue to use Mozilla's webidl since, whilst it was extracted from the draft using a similar process, their current implementation is incomplete and as such it has been heavily modified (many interfaces commented out, etc.) by hand and isn't useful for targeting the more complete implementations available in Chrome and Safari.