function splitSentence( sentence, language ) {
	const stopwordRegex = languageVariables[ language ].stopwordRegex;
	const stopwords = sentence.match( stopwordRegex ) || [];
	const splitSentences = splitOnWords( sentence, stopwords );
	return createSentenceParts( splitSentences, language );
}
function splitSentence( sentence, language ) {
	const stopwordRegex = languageVariables[ language ].stopwordRegex;
	const stopwords = sentence.match( stopwordRegex ) || [];
	const splitSentences = splitOnWords( sentence, stopwords );
	return createSentenceParts( splitSentences, language );
}
function splitSentence ( sentence , language ) { const stopwordRegex = languageVariables [ language ] . stopwordRegex ; const stopwords = sentence . match ( stopwordRegex ) || [ ] ; const splitSentences = splitOnWords ( sentence , stopwords ) ; return createSentenceParts ( splitSentences , language ) ; }
Splits the sentence into sentence parts based on stopwords.

@param {string} sentence The text to split into sentence parts.
@param {string} language The language for which to split sentences.

@returns {Array} The array with sentence parts.
Splits the sentence into sentence parts based on stopwords .