Page Menu
Home
WickedGov Phorge
Search
Configure Global Search
Log In
Files
F4136445
init.js
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
960 B
Referenced Files
None
Subscribers
None
init.js
View Options
$
(
()
=>
{
const
useSecureEnclave
=
require
(
'./secureEnclave.js'
);
const
config
=
require
(
'./config.json'
);
const
visualEditorInitPluginsCallback
=
require
(
'./ve/initPlugins.js'
);
if
(
config
.
HCaptchaEnterprise
&&
config
.
HCaptchaSecureEnclave
)
{
useSecureEnclave
(
window
);
}
// If VisualEditor is available, then register the hCaptcha plugins.
//
// The VisualEditor scripts are loaded if they are one of loaded, loading, ready,
// or registered (the exact state depending on when this code is run).
// If it is 'missing' then we should not need to respond to any
// VisualEditor edit on this page.
const
veState
=
mw
.
loader
.
getState
(
'ext.visualEditor.targetLoader'
);
const
validStates
=
[
'loading'
,
'loaded'
,
'ready'
,
'registered'
];
if
(
validStates
.
includes
(
veState
)
)
{
mw
.
loader
.
using
(
'ext.visualEditor.targetLoader'
).
then
(
()
=>
{
mw
.
libs
.
ve
.
targetLoader
.
addPlugin
(
visualEditorInitPluginsCallback
);
}
);
}
}
);
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Aug 19, 13:42 (3 w, 3 d ago)
Storage Engine
local-disk
Storage Format
Raw Data
Storage Handle
f4/ba/303718bc0357a9f92d8366b513f1
Default Alt Text
init.js (960 B)
Attached To
Mode
rMWPROD MediaWiki Production
Attached
Detach File
Event Timeline
Log In to Comment