<commit_before>//
// Author: CYOSP
// Created: 2016-10-21
// Version: 1.1.0
//

// 2016-10-22 V 1.1.0
//   - Execute cythsInit function (if it exists)
//     after internationalization 
// 2016-10-21 V 1.0.0
//   - Initial release

//
// i18next configuration
//
var i18nextOptions =
{
	// evtl. use language-detector https://github.com/i18next/i18next-browser-languageDetector
    lng: navigator.language || navigator.userLanguage, 
	fallbackLng: 'en',
	load: 'currentOnly',
	backend:
	{
		// i18nextLoadPath must be declared as a global variable
		loadPath: i18nextLoadPath
    }
}

//
// i18next initialization
//
i18next.use( i18nextXHRBackend ).init( i18nextOptions , function(err, t)
{
	// For options see: https://github.com/i18next/jquery-i18next#initialize-the-plugin
	jqueryI18next.init( i18next , $ );
<commit_msg>Call cythsBeforeLocalize function before internationalization<commit_after>//
// Author: CYOSP
// Created: 2016-10-21
// Version: 1.2.0
//

// 2016-10-27 V 1.2.0
//   - Execute cythsBeforeLocalize function (if it exists)
//     before internationalization 
// 2016-10-22 V 1.1.0
//   - Execute cythsInit function (if it exists)
//     after internationalization 
// 2016-10-21 V 1.0.0
//   - Initial release

//
// i18next configuration
//
var i18nextOptions =
{
	// evtl. use language-detector https://github.com/i18next/i18next-browser-languageDetector
    lng: navigator.language || navigator.userLanguage, 
	fallbackLng: 'en',
	load: 'currentOnly',
	backend:
	{
		// i18nextLoadPath must be declared as a global variable
		loadPath: i18nextLoadPath
    }
}

//
// i18next initialization
//
i18next.use( i18nextXHRBackend ).init( i18nextOptions , function(err, t)
{
	// For options see: https://github.com/i18next/jquery-i18next#initialize-the-plugin
	jqueryI18next.init( i18next , $ );

	// Before internationalization is performed
	// Call CYTHS before localize if defined
	if( typeof cythsBeforeLocalize !== 'undefined' && $.isFunction( cythsBeforeLocalize ) )
	{
		cythsBeforeLocalize();
	}

{'fraction_non_alphanumeric': 0.13395946613939694, 'fraction_numerical': 0.0657439446366782, 'mean_word_length': 3.2521008403361344, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 4, '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': '4219856', 'n_tokens_mistral': 794, 'n_tokens_neox': 700, 'n_words': 158}