Skip to content

concern about a module graph per realm for the web #261

@caridy

Description

@caridy

@domenic raised this concern during a conversation today. From what I gathered, the main issue will be to have more than one module graph per window. He think this is problematic due to how intertwine these two concepts are. Also mentioned memory, and allocation of multiple instances of the same module source as another potential issue.

From the proposal perspective, the reason to not reuse the module graph from the incubator realm is mostly because 2 reasons:

  • virtualization/integrity: if your dependencies are running outside the realm, using a different global object, you can't consider the realm an integrity boundary.
  • identity continuity: anything that you import uses the same intrinsics.

Up to this point, reusing module instances from other realms was only possible via the compartments API (another proposal).

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions