I am working on this script and would like to make the table sortable. I am not entirely sure how to do that. I was hoping it would be as simple as replicating the HTML but clearly that isn't enough. My guess is I somehow have to load the script for sortable tables manually as ResourceLoader probably runs before custom JS.
Does anyone know if that is true? What do I need to do to insert a sortable table?
Edit:
Upon going to "MediaWiki:Interwiki_map/full", the script is supposed to use the API to get a full list of interwiki prefixes. The list can optionally be filtered using the API parameter "sifilteriw" which the user can set via the URL query string (replicating both the parameter name and valid values). Once the data has been retrieved, the script constructs the table and then inserts the pre-defined notice and the table onto the page.
Also, as a side question, I got help here with another script that I now want to move to the wiki as well. Does anyone know of a way to move it into the MediaWiki namespace? I tried exporting-importing-renaming but Wikia won't let me rename pages into the namespace. I also tried exporting-modifying-importing but Wikia also won't let me import into the namespace (importing a modified file is not a problem, I tested it). Right now, my only option seems to be to create the page and then copy-paste the script. I was kind of hoping to retain the page history.