getTitle();
if ( $title->getNamespace() === NS_AV_ANNOT ) {
$out = $editor->getContext()->getOutput();
$out->addModules('ext.annot.prev');
}
return true;
}
/**
* Small helper function to display information on the browser console
*
* Usage:
* echo '';
*
* @param $data information to display
* @param bool $add_script_tags true to put information is inside complete script tag
*/
public static function console_log($data, $add_script_tags = false) {
$command = 'console.log('. json_encode($data, JSON_HEX_TAG).');';
if ($add_script_tags) {
$command = '';
}
echo $command;
}
}