Help:JavaScript review process

To help provide a secure environment for Wikia's users, a community JavaScript review process has been developed.

This process means that any edits to community JS will not be served to visitors until they have been checked and approved by a member of Wikia's trusted review team.

The feature is being rolled out across Wikia, and is subject to change - significant updates and news will be posted on the. If you need it enabled on your community, please feel free to request it via Special:Contact/general.

How does it work?
When the feature is enabled on your community, pages in the MediaWiki: namespace ending in *.js become editable by local admins.

Edits to these pages will not affect what visitors receive until you submit the page for review. Wikia's review team will then check your JS and approve or reject it.
 * If it is approved, the changes will immediately become active on your community.
 * If it is rejected, a notice will be shown on the JS page, and an explanatory note will likely be left on the talk page.

So that you easily can test JS edits, the process introduces "test mode", which allows your account to run unreviewed JS. Test mode is activated on a per-community basis, covers all local scripts, and lasts until disabled.

The status of individual scripts on your community are listed in a module to the right of that JS page, and on Special:JSPages. The module and special page are where you can submit updates for approval and enable test mode. Monobook users can find the module via the 'review status' tab.

What are the criteria for approval?
With the introduction of the JS review tool, Wikia is introducing some new rules about how JS may be written. Note that these rules are subject to change.


 * All JS must be written in a clear, readable format. Any obfuscated code will be rejected.
 * All on-Wikia imports must be stored on MediaWiki namespace pages that end with ".js"
 * User namespace imports will not be allowed (see FAQ below)
 * Scripts stored outside Wikia will be approved on a case-by-case basis.
 * Any clear customization policy or violations will be rejected (e.g. hiding ads, collecting user data, major site layout changes).
 * JS that causes errors will be rejected.

Note: the approval process is not a review of the general quality of your code, nor about making judgement calls about how useful or valid a JS feature is. While we will let you know about serious problems, we won't be able to rewrite the code for you.

FAQ

 * How long will it take for my edits to be reviewed?
 * We aim for a speedy process - we don't want to get in the way of useful JS as much as possible. Scripts will be reviewed on a first-come, first-served basis.
 * Note that Wikia's JS-related tools are in ongoing development - more tweaks and improvements are likely.


 * What if I need to make more edits after I submit my script for review?
 * Each JS page can only have one revision in the review queue. While you can make further edits after requesting a review, only the originally requested revision will be reviewed. If you want us to review a newer version, simply submit the page for review again - this will overwrite the previous request.


 * What exactly happens when a JS edit is rejected?
 * A notice will be shown on the JS page review module, and an explanatory note will likely be left on the talk page. Previously approved JS will continue to work as normal. We do not revert the edits that were rejected, since only a small tweak may be required to allow it to be approved.


 * Why will you reject imports from the User namespace?
 * We would eventually like to re-allow unrestricted editing of User namespace *.js pages (beyond personal JS), but this cannot occur until they are no longer used in community JS. If you trust a user enough to run JS they have written, consider whether the user should be an admin, or copy their JS to the MediaWiki namespace.


 * What happens to scripts created before the tool's introduction?
 * They are pre-approved (we don't want to unnecessarily break customizations that work fine today), but this is subject to change.


 * How does test mode work?
 * While visitors will only be served approved revisions of JS scripts, enabling test mode allows your account to be served the latest revisions. This should make it easier to test changes to your community's JS without worrying about it temporarily breaking the site for everyone!
 * It is enabled on a per-account, per-community basis, covers all scripts used on that community, and lasts until disabled or you log out.
 * Note that you may need to bypass your browser cache to see the latest edits.


 * How does approval work for cross-community imports?
 * If you import a script from another community, only approved versions will be served. This includes when test mode is enabled on your home community. You will have to enable test mode on the other community to receive the latest revision from there.


 * Does this affect personal JS?
 * No - the core personal JS pages (e.g. User:Wikia/common.js) remain freely editable. The rules about what you can do in community JS pages do not apply to personal JS.


 * I have feedback or ideas about the tool!
 * Please let us know your feedback via Special:Contact!

de:Hilfe:JavaScript-Überprüfungsprozess es:Ayuda:Proceso de revisión de JavaScript fr:Aide:Processus de vérification du JavaScript it:Aiuto:Processo di revisione del JavaScript ja:ヘルプ:JavaScriptの審査プロセス nl:Help:JavaScript evaluatieproces pl:Pomoc:Proces przeglądu kodu JavaScript pt:Ajuda:Processo de revisão de JavaScript ru:Справка:Проверка JavaScript vi:Trợ giúp:Quá trình xem xét JavaScript zh:Help:JavaScript審核流程