https://bugzilla.wikimedia.org/show_bug.cgi?id=47296

--- Comment #13 from Jon <[email protected]> ---
This is now less of a problem in mobile as we have reduced the possibility of
this happening to only situations where a module has been renamed/typed
incorrectly/ is not available due to being in mobile mode rather than desktop.
The tablesorter exception is no longer called.

My main worry about this is that since ResourceLoader concatenates code one
module failing can prevent the execution of another module. This seems wrong. I
can understand an entire module from throwing an exception and not executing
but stopping all javascript from executing seems wrong.

I really don't understand the need for an exception under all circumstances.
Could we not default the error handler to throwing an exception to at least
allow developers to override it. For example a gadget might want to do
something with a module if it's available but fail silently if it's not so it
can be used on as many wiki's as possible that may or may not have the module
it does something with)

// module 1
mw.loader.using( 'foobar', function() {
} );

// module 2
(function(){ alert( 4 ); })()

On a similar subject it would be great to see mw.loader.using return a
jQuery.deferred object.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
Wikibugs-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l

Reply via email to