Note that jquery.json will be removed in 1.25
authorMatthew Flaschen <mflaschen@wikimedia.org>
Fri, 11 Jul 2014 20:43:09 +0000 (16:43 -0400)
committerMatthew Flaschen <mflaschen@wikimedia.org>
Fri, 11 Jul 2014 21:05:41 +0000 (17:05 -0400)
This is a pretty straightforward migration, and improves performance
for users with modern browsers (since the skip function means
browsers with native JSON don't need to download a JSON module)

Stating a removal version will encourage this migration.

Change-Id: I8fe83f30fd27f7bfe50e756846486abdadb91189

resources/src/jquery.json-deprecate.js

index 915cd85..f38decd 100644 (file)
@@ -1,4 +1,6 @@
 ( function ( mw, $ ) {
+       // @deprecated since 1.24.  The 'jquery.json' module will be removed in MW 1.25.  Use the 'json' module.
+
        mw.log.deprecate( $, 'toJSON', $.toJSON, 'Use JSON.stringify instead (module "json" for polyfill).' );
        mw.log.deprecate( $, 'evalJSON', $.evalJSON, 'Use JSON.parse instead (module "json" for polyfill).' );
        mw.log.deprecate( $, 'secureEvalJSON', $.secureEvalJSON, 'Use JSON.parse instead (module "json" for polyfill).' );