From 9350df7111098482ecd5f486aecb7c6e34ba950d Mon Sep 17 00:00:00 2001 From: Sam Smith Date: Mon, 22 May 2017 19:16:17 +0100 Subject: [PATCH] doc: Document schema module Bug: T158236 Change-Id: I365fbfc1725d92003e902301252d53d4620c2128 --- resources/dist/index.js.map | Bin 265851 -> 266419 bytes src/schema.js | 12 ++++++++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/resources/dist/index.js.map b/resources/dist/index.js.map index c955fb3c8e43698c24addc0f3b8fdaa31877109c..0ec01684f114dba3a76421c95bb38f089c7b264e 100644 GIT binary patch delta 757 zcmex8M_}_pfe8sBNoL7rsm7)$#;K_$$;OsR$w}sxlOHllZS1=>m$7Pc<~$9?kAMl95q+a@}%S#;WEy%eT*2&gj!S{Xry?0C#b6Mrv+i zOrC<4{`C9pjF!_Ua58dCH&9^|u8(#tOU*0s$xlzu%u81Y1}juZ&PgmTj*T{mRVdFa z$xujCC{D~R$N?$<8KF>=SdyxcpQeydo*s~2P+Cw7(G?6;69kk_P{>SED9K1w2z68_ zE-fg?FDfZkhz1Ebr6wll=P5V_c*aH>#>Pm349qW5NH73v$t+Pw$xkiLQ!mk*uD^xJ zfd|=j)9bb{Nlt$(%Pg#=msJdQ3eX5Eg^ZGtf?_Lu{c_`Ey>y^^OOy06^YxR!7U@r4 zXwE1yT_KK9aC$=tBl~u)=ge7*+qun|l6A30)%5S_Ogq}GQkk|}r80{*PJeKLi9^^S SH$SB`CskoI9FfDZP#pl0Rs&}M delta 368 zcmdnIP~i6*fe8sBX{JV|28NcF#^z>*76vIMW+sWLlOHllZS1=>m(hH3<~$9?(8+rX zq$aPKw~8@ubNKw*tnwC>?!HE$I+@On&W<|4j*g*uSx!2xj*fvYI_}xdd6NT|ZdS-Q zbN9_m)+u*_sVP9H$#u3g+pMxIl991=a@}%S#;oQ!%eT*2&gj!Sz0QKkZhHJCCO-Sb zJO$UX)Vva({Pgt9ymW=)e2RjsZ87Fr81vyoUZVinHCmjF>YV;ikV#v E01^6skpKVy diff --git a/src/schema.js b/src/schema.js index 870f65349..cdacddbd6 100644 --- a/src/schema.js +++ b/src/schema.js @@ -1,9 +1,17 @@ +/** + * @module schema + */ + var mw = window.mediaWiki, $ = jQuery; /** - * Creates an instance of an EventLogging schema that can be used to log - * Popups events. + * Creates an instance of the [EventLogging Schema class][0] with a sampling + * rate of `wgPopupsSchemaSamplingRate` if the UA supports [the Beacon API][1] + * or `0` if it doesn't. + * + * [0]: https://github.com/wikimedia/mediawiki-extensions-EventLogging/blob/master/modules/ext.eventLogging.Schema.js + * [1]: https://w3c.github.io/beacon/ * * @param {mw.Map} config * @param {Window} window