currently, resourceloader can (dynamically) filter gadgets, based, e.g., on "skin", meaning some gadget may load or not load for a particular user based on "useskin" parameter to index.php. it would be nice to extend this dynamic filtering functionality, for "action" and "namespace", and possibly for special page name.
some gadgets are only useful in certain actions or certain namespaces. such gadgets can be pretty heavy: for instance, wikEd (enwiki) can be safely limited to action=edit|submit, and the heavy commons gadget Cat-a-lot is only useful in the category namespace.
teach resourceloder to filter with actions= and namespaces= like so:
bonus points: add "special", e.g., special=Watchlist,RecentChanges,Contributions - there are quite a few gadgets that only do something useful in one of those special pages, and it would be nice to avoid loading them (and their dependencies) elsewhere.
tried to look for a similar request and did not find any. if there is such' please mark as dupe.