Re: [w3c/webcomponents] HTML Modules: multiple scripts exporting same named export (#831)

> I assume SystemJS differs from the native JavaScript module behavior in the same way

Yeah I think so -- all js modules loadable by systemjs are ultimately converted to the [System.register format](https://github.com/systemjs/systemjs/blob/master/docs/system-register.md#format-definition), which is an es5 format that emulates almost all of the js module nuances, including live bindings via the `setters` property. Up until now, I thought it perfectly emulated everything about js modules, but your explanation clarifies that it does not handle this one particular edge case. But notice that the module dependencies only specify the module name, not which exports from the module they need. And that the `setters` property is given the entire module, not just the imports it asked for.

I consider my question to be answered, but will leave this issue open in case you want to use it to track that clarifying scenario in the spec explainer doc.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3c/webcomponents/issues/831#issuecomment-526431972

Received on Friday, 30 August 2019 02:34:13 UTC