Status
QuickJS itself can execute modern ECMAScript, but MacSurf's browser script loader still lacks the web module-script pipeline. The current capability audit records <script type="module"> as silently dropped.
This is distinct from JavaScript syntax support: module scripts require browser-side URL resolution, fetch ordering, module graph/linking, realm ownership, error/load events, and execution semantics.
V1 scope
- Recognize
<script type="module" src=...> and inline module scripts.
- Resolve static imports relative to the referring module URL.
- Fetch each module once per realm/module map and link through QuickJS's module loader hooks.
- Preserve defer-like module execution ordering and document lifecycle interaction.
- Fire script
load/error correctly.
- Surface unsupported/failing modules explicitly rather than silently dropping them.
Dynamic import() and import maps may be follow-up rounds if they require separate infrastructure.
Acceptance
A controlled entry module imports a second relative module, both execute exactly once in the correct order, exported/imported values work, load/error behavior is deterministic, and the page reaches the expected DOM result on the G3. Include failure and duplicate-import tests.
Status
QuickJS itself can execute modern ECMAScript, but MacSurf's browser script loader still lacks the web module-script pipeline. The current capability audit records
<script type="module">as silently dropped.This is distinct from JavaScript syntax support: module scripts require browser-side URL resolution, fetch ordering, module graph/linking, realm ownership, error/load events, and execution semantics.
V1 scope
<script type="module" src=...>and inline module scripts.load/errorcorrectly.Dynamic
import()and import maps may be follow-up rounds if they require separate infrastructure.Acceptance
A controlled entry module imports a second relative module, both execute exactly once in the correct order, exported/imported values work, load/error behavior is deterministic, and the page reaches the expected DOM result on the G3. Include failure and duplicate-import tests.