Explain xkcd: It's 'cause you're dumb.
importScriptURI('http://en.wikipedia.org/w/index.php?title=User:Js/6tabs-vector.js&action=raw&ctype=text/javascript');
importScriptURI('http://en.wikipedia.org/w/index.php?title=User:Markhurd/hidetopcontrib.js&action=raw&ctype=text/javascript');
// Create portlet link
var portletLink = mw.util.addPortletLink( 'p-namespaces', '#',
'My new portlet link', 'ca-my-portlet', 'Click here to test the new portlet'
);
// Bind click handler
$( portletLink ).click( function ( e ) {
e.preventDefault();
// doSomeStuff();
alert( 'It works!' );
});