import { toCamelCase } from "../parsers/string"; import { unimportantWords } from "../tokenizer/vocabulary"; /** * Generates a variable name based off of word context */ export function createVariableName( words: string[] ) { return toCamelCase(words .filter( word => !unimportantWords.some( x => x.toLowerCase() === word.toLowerCase() ) ) ).match(/[a-z0-9]/ig)?.join(''); }