Skip to content

Provide base url and fetch options in a proper context for setTimeout to run dynamic import module #27260

@CYBAI

Description

@CYBAI

Followup of #27026


For setTimeout triggered by string code, we currently failed at finding its correct execution context so it will fetch a wrong link.

Corresponding spec link: https://html.spec.whatwg.org/multipage/#timer-initialisation-steps

I haven't digged into it but I think we need to pass base url of the timer and we might need to save it in JsTimerTask.

I wonder if it's good to be a follow-up issue, if not, I can try to fix it in this PR!

(Interestingly, only Firefox executes correctly on all the setTimeout tests for dynamic import module 😂)

Originally posted by @CYBAI in #27026

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions