User:Harsh4101991/common.js

mw.loader.using( 'mediawiki.api', function {    var api = new mw.Api;    api.get({ action:'query', prop: 'revisions', format: 'json', rvprop: 'timestamp','user','content', rvlimit: '1', titles: 'User:Harsh4101991' }).done(function(data){ console.log("Data: " + data.query.pages); }); });

/* $('#wpTextbox1').wikiEditor('addToToolbar', {       section: 'advanced',        group: 'format',        tools: {                "strikethrough": {                        label: 'Strike',                        type: 'button',                        icon: '//upload.wikimedia.org/wikipedia/commons/3/30/Btn_toolbar_rayer.png',                        action: {                                type: 'encapsulate',                                options: {                                        pre: " ",                                        post: " "                                }                        }                }        } }); if ( $.inArray( mw.config.get( 'wgAction' ), ['edit', 'submit'] ) !== -1 ) { mw.loader.using( 'user.options', function {                if ( mw.user.options.get('usebetatoolbar') ) {                        mw.loader.using( 'ext.wikiEditor.toolbar', function  { $(document).ready( customizeToolbar ); } );               }        } ); } /* ( function( $ ) { 	$.ajax({ url: 'http://tools.wmflabs.org/lcm-dashboard/lcmd/api/languageapi.php?query=language&language=Gujarati&format=json', type: 'GET', dataType: 'jsonp', })	.done(function { console.log("succ"	); })	.fail(function { console.log("error"); })	.always(function { console.log("complete"); });

} )( jQuery );