<commit_before><?php
/**
 * @link https://github.com/nezhelskoy/yii2-highlight
 * @copyright Copyright (c) 2014 <NAME>
 * @license "BSD-3-Clause"
 */

namespace nezhelskoy\highlight;

use yii\web\AssetBundle;

/**
 * Asset bundle for the Highlight.js library.
 *
 * @author <NAME> <<EMAIL>>
 */
class HighlightAsset extends AssetBundle
{
    public $sourcePath = '@vendor/nezhelskoy/yii2-highlight/';
    public $css = [
        'dist/styles/default.css',
    ];
    public $js = [
        'dist/highlight.pack.js',
    ];
    public $depends = [
        'app\assets\AppAsset',
    ];

    public static function register($view)
    {
        $view->registerJs('hljs.initHighlightingOnLoad();');
        parent::register($view);
    }
}<commit_msg>Added possibility of a global library configuration<commit_after><?php
/**
 * @link https://github.com/nezhelskoy/yii2-highlight
 * @copyright Copyright (c) 2014 <NAME>
 * @license "BSD-3-Clause"
 */

namespace nezhelskoy\highlight;

use yii\web\AssetBundle;

/**
 * Asset bundle for the Highlight.js library.
 *
 * @author <NAME> <<EMAIL>>
 */
class HighlightAsset extends AssetBundle
{
    public $sourcePath = '@vendor/nezhelskoy/yii2-highlight/';
    public $css = [
        'dist/styles/default.css',
    ];
    public $js = [
        'dist/highlight.pack.js',
    ];
    public $depends = [
        'app\assets\AppAsset',
    ];

    /*
     * @var string the options to be declared as js object with global [configuration](http://highlightjs.readthedocs.org/en/latest/api.html#configure-options)
     */
    public static $options = '{}';

    public static function register($view)
    {
        $view->registerJs('hljs.initHighlightingOnLoad(' . self::$options . ');');
        parent::register($view);
    }
}
{'fraction_non_alphanumeric': 0.155631013016412, 'fraction_numerical': 0.00792303338992643, 'mean_word_length': 2.9641255605381165, 'pattern_counts': {'":': 0, '<': 13, '<?xml version=': 0, '>': 13, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3781176', 'n_tokens_mistral': 594, 'n_tokens_neox': 566, 'n_words': 113}