mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/VisualEditor
synced 2024-12-13 14:58:43 +00:00
10 lines
307 B
JavaScript
10 lines
307 B
JavaScript
|
// In VE-MW, track events using MediaWiki's system instead of VisualEditor's
|
||
|
ve.track = mw.track;
|
||
|
ve.trackSubscribe = mw.trackSubscribe;
|
||
|
|
||
|
ve.trackSubscribe( 'activity.', function ( topic, data ) {
|
||
|
mw.track( 'visualEditorFeatureUse', ve.extendObject( data, {
|
||
|
feature: topic.split( '.' )[ 1 ]
|
||
|
} ) );
|
||
|
} );
|