<commit_before>import { stringify } from 'rebem-classname';
import Set from 'core-js/es6/set';

export function isPropsMatchBEM(props, bemjson) {
    const targetClasses = new Set(stringify(props).split(' '));
    const matchClasses = stringify(bemjson).split(' ');

    return matchClasses.every(matchClass => targetClasses.has(matchClass));
}<commit_msg>:heavy_check_mark: throw validation warnings for BEMJSON, but not for node props<commit_after>import { stringify, validate } from 'rebem-classname';
import Set from 'core-js/es6/set';

export function isPropsMatchBEM(props, bemjson) {
    const targetClasses = new Set(stringify(props).split(' '));
    const matchClasses = stringify(validate(bemjson)).split(' ');

    return matchClasses.every(matchClass => targetClasses.has(matchClass));
}
{'fraction_non_alphanumeric': 0.13016270337922403, 'fraction_numerical': 0.0025031289111389237, 'mean_word_length': 5.896551724137931, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 0, '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': '1941802', 'n_tokens_mistral': 238, 'n_tokens_neox': 233, 'n_words': 55}