Skip to content

docs(quest): plan web and WASI as separate wasm targets - #685

Merged
kixelated merged 1 commit into
mainfrom
quest-plan/wasm-web-wasi
Nov 10, 2026
Merged

kixelated merged 1 commit into
mainfrom
quest-plan/wasm-web-wasi

Conversation

@kixelated

@kixelated kixelated commented Nov 10, 2026 •

Copy link
Copy Markdown
Collaborator

Problem

#684 left rust2-wasm's clock open and recommended one wasm32-wasip1 module whose imports the binding satisfies. The maintainer decided otherwise: web and WASI are separate targets, and the web's uses web APIs where one exists, performance.now for its clock.

Approach

Quest files only.

  • quest/m2/wasm/backend.md is now the web target: its clock, randomness, and stderr are web APIs called directly, with nothing of WASI in the bundle. What stays open is only how a stock crate's std::time reaches performance.now, since std for wasm32-unknown-unknown has no clock and no hook for one.
  • New quest/m3/wasi.md: a report on a WASI target for hosts with no JavaScript, as a core module over the C ABI or as a component with generated WIT.
  • The epic and m3 record the decision.

Decisions

Choice made without asking, for review: the web target's recommended mechanism is still to compile against wasm32-wasip1's std and bind each import the module declares to its web API in the generated binding, with the import names an internal detail and no WASI runtime shipped. The alternatives listed are a source change in the crate, a patched std, or a web std of rustc's own if one exists.

Impact

  • No code or public API changes.

Alternatives

  • Keeping one quest with two flavors: rejected, since the WASI target has no consumer and the web target is on moq's path.

Follow-ups

None.

Models

Size: S
Implementer: Claude Code, claude-fable-5-2, high effort

🤖 Generated with Claude Code

(Written by Claude Fable 5 with high)

Review

Rewritten by quest review after each round.

  • Reviewer: Codex, gpt-6.1-sol, medium effort
  • Session: 01a1c306-97bd-78d1-ac3a-068406d4030b, round 1
  • Head: 40d7400
  • Base: origin/main at 6890691
  • Score: 9/10, The diff changes planning documents only, with a coherent web/WASI split and implementation choices explicitly left for investigation; no actionable defects were found.
  • Findings: none

The web target calls web APIs directly, performance.now for its clock, and ships nothing of WASI. A WASI target for hosts with no JavaScript is its own m3 quest.

Co-Authored-By: Claude <noreply@anthropic.com>
@pullfrog

pullfrog Bot commented Nov 10, 2026

Copy link
Copy Markdown

Pullfrog  | Review this ➔

@kixelated
kixelated marked this pull request as ready for review November 10, 2026 01:16
@coderabbitai

coderabbitai Bot commented Nov 10, 2026

Copy link
Copy Markdown

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 4 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 86401574-fa06-4c34-b2fa-005cbc1090e0
Commits

Reviewing files that changed from the base of the PR and between 6890691 and 40d7400.

Files selected for processing: 7

  • quest/m2/wasm/README.md
  • quest/m2/wasm/backend.md
  • quest/m2/wasm/routes.md
  • quest/m3/README.md
  • quest/m3/node.md
  • quest/m3/react-native.md
  • quest/m3/wasi.md
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@kixelated
kixelated added this pull request to the merge queue Nov 10, 2026
Merged via the queue into main with commit 22485b3 Nov 10, 2026
7 checks passed
@kixelated
kixelated deleted the quest-plan/wasm-web-wasi branch November 10, 2026 01:21
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