(This pretty much just repeats what hax said...)

> `load` is a method, which can be called anywhere.  Having it depend on
> a dynamically-scoped bit of information such as the url of the file
> that the method is called in, would make using loaders much harder to
> understand.
>

Perhaps, but I fear this will limit the usefulness of dynamic loading to
absolute URLs.  If a programmer writes:

    System.load("my-file.js", Module => { ... });

It's highly unlikely that they care about the URL of the page or the
baseURL of the current loader or any other "remote knowledge" like that.
 It's just not modular : )

This is just like current browser behavior when you insert a `<script
> src="test.js">` tag -- "test.js" is looked up relative to the URL of
> the *page*, not relative to the URL of the js file that does the dom
> manipulation.
>

: )  Yes, and that behavior makes loading anything other than absolute
URLs, um, "tricky".

Kevin
_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss

Reply via email to