tc39 / proposal-dynamic-import-host-adjustment

TC39 proposal that affects doesn't stringify argument to import(...) early to enable interop with WICG/trusted-types
MIT License
18 stars 3 forks source link

Clarify effect on module loader cache and module reuse #3

Open mikesamuel opened 4 years ago

mikesamuel commented 4 years ago

Host internal caches key on strings to prevent repeated fetching and loading of semantically-equivalent module references. This proposal should not affect or complicate that.

@bmeck, you raised during plenary that implementations often have corner cases around garbage collection with cross-realm GC. Do I understand correctly that this is a concern re module-reference-string-wrapping objects as keys into per-realm caches related to import(moduleReferenceFromAnotherRealm)? Or is that a separable issue?

bmeck commented 4 years ago

This is true, I have lots of docs on this from our node loader work, but would prefer if we could sync up and try and disseminate what the pieces that truly affect the intent of the proposal sometime.