Translate extension for MediaWiki
Loading...
Searching...
No Matches
ScribuntoHookHandler.php
1
<?php
2
3
namespace
MediaWiki\Extension\Translate\MessageBundleTranslation;
4
5
use MediaWiki\Extension\Scribunto\Hooks\ScribuntoExternalLibrariesHook;
6
7
class
ScribuntoHookHandler
implements
ScribuntoExternalLibrariesHook {
8
public
function
onScribuntoExternalLibraries(
string
$engine, array &$extraLibraries ):
void
{
9
if
( $engine !==
'lua'
) {
10
return
;
11
}
12
13
$extraLibraries[
'mw.ext.translate.messageBundle'
] = [
14
'class'
=> MessageBundleLuaLibrary::class,
15
'deferLoad'
=> true
16
];
17
}
18
}
MediaWiki\Extension\Translate\MessageBundleTranslation\ScribuntoHookHandler
Definition
ScribuntoHookHandler.php:7
src
MessageBundleTranslation
ScribuntoHookHandler.php
Generated by
1.10.0