This script/stylesheet is for PERSONAL use only!
You are free to install this script/stylesheet for yourself, but it is not allowed to be used wiki-wide (e.g., in MediaWiki:ImportJS, MediaWiki:Common.js, MediaWiki:Common.css, MediaWiki:Fandomdesktop.js, MediaWiki:Fandomdesktop.css, or MediaWiki:FandomMobile.css), as it would violate Fandom's Terms of Use.
(See the customization policy)
AutoPurge es un fragmento de JavaScript que permite a los usuarios purgar automáticamente ciertas páginas enumeradas en una matriz
window.autoPurgePages.
Alternativamente, si los usuarios desean purgar todas las páginas en un espacio de nombres específico, esto se puede lograr mediante una ligera modificación de la variable de la ventana, como se muestra en la sección "Instalación".
Installation
Las páginas que el usuario desea que se purguen automáticamente se almacenan en una variable de ventana, que se insertará antes de la declaración
importArticles:
window.autoPurgePages = ["User:Fandom", "User_talk:Fandom"];
Alternativamente, si el usuario desea purgar cada página en un espacio de nombres, se puede usar el siguiente código:
if (mw.config.get("wgNamespaceNumber") === 2) {
window.autoPurgePages = [mw.config.get("wgPageName")];
}
Using configuration options with Fandom Developers Wiki scripts
The instructions on this page describe how to use configuration options with a script. Here on the Fandom Developers Wiki, many scripts provide optional configuration settings as a mean to alter or enhance the default behavior of the script. When installing configuration options in your JavaScript file, please note that they need to go above the import statement in order to work — unless the directions say otherwise. In case MediaWiki:ImportJS is used to load the scripts, it will be executed last.
// 1. AjaxRC import statement
importArticles({
type: 'script',
articles: [
'u:dev:MediaWiki:AjaxRC.js'
]
});
// 2. AjaxRC configuration option
window.ajaxRefresh = 30000;
// 1. AjaxRC configuration option
window.ajaxRefresh = 30000;
// 2. AjaxRC import statement
importArticles({
type: 'script',
articles: [
'u:dev:MediaWiki:AjaxRC.js'
]
});
Registro de cambios
| Date | Description |
|---|---|
| August 4, 2017 | Initial revision. |