Load all default words joined with additional worsd from a config file

@param {string|string[]} words
@return {string[]}
192473
function getWords(words) {
	const defaults = loadJson('./words.json');
	const extras = typeof words === 'string' ? loadJson(words) : words;
	return defaults.concat(extras);
}
446067
function addWord(word) {

    var branch = this.root;
    var stopSearchOnCurrentBranch = false;
    var newNode;

    while (!stopSearchOnCurrentBranch) {
      var wordContainsThePrefix = false;
      var isCase3 = false;
      var case2Result;

      //Looks for how branch it should follow
      for (var b in branch.branches) {

        //Case 1: current node prefix == `word`
        if(this._tryCase1(branch, word, b)) {
          return;
        }

        //Case 2: `word` begins with current node prefix to add
        //Cuts the word and goes to the next branch
        case2Result = this._tryCase2(branch, word, b);
        if(case2Result) {
          word = case2Result.word;
          branch = case2Result.branch;
          wordContainsThePrefix = true;
          break;
        }

        //Case 3: current node prefix begins with part of or whole `word`
        if(this._tryCase3(branch, word, b)) {
          isCase3 = stopSearchOnCurrentBranch = wordContainsThePrefix = true;
          break;
        }
      }

      //Case 4: current node prefix doesn't have intersection with `word`
      if(this._tryCase4(branch, word, wordContainsThePrefix)) {
        stopSearchOnCurrentBranch = true;
      }
    }
  }
927004
function computeWords(text) {
    var words = text.split(/\s+/g); // To hyphenate: /\s+|(?<=-)/
    if (!words[words.length - 1]) words.pop();
    if (!words[0]) words.shift();
    return words;
}
298841
def _setup(self, word) -> List[str]:
        
        if len(word) == 1:
            return [word]
        for prefix in self.constants.PREFIXES:
            if word.startswith(prefix):
                (first, rest) = string_utils.split_on(word, prefix)
                if self._contains_vowels(rest):
                    return string_utils.remove_blank_spaces(
                        self._process(first) + self._process(rest))
                # a word like pror can happen from ellision
                return string_utils.remove_blank_spaces(self._process(word))
        if word in self.constants.UI_EXCEPTIONS.keys():
            return self.constants.UI_EXCEPTIONS[word]
        return string_utils.remove_blank_spaces(self._process(word))
1169884
function Words(superwords, classwords) {
	this.classwords = getwords(classwords, ['extend', 'mixin']);
	this.superwords = getwords(superwords, ['this._super']).map(function dot(
		word
	) {
		return word + '.';
	});
}
948848
function common(words) {
  return _.map(words, function(o) {
    return o.word.toLowerCase();
  }).sort();
}
1286563
function string_to_words(string) {
	var words = [];
	for (var i = 0; i < string.length; i += 4) {
		words.push(string.charCodeAt(i) << 24 | string.charCodeAt(i + 1) << 16 | string.charCodeAt(i + 2) << 8 | string.charCodeAt(i + 3));
	}
	return words;
}
329286
function makePredicate(words) {
      if (!(words instanceof Array)) words = words.split(" ");
      var f = "", cats = [];
      out: for (var i = 0; i < words.length; ++i) {
          for (var j = 0; j < cats.length; ++j)
              if (cats[j][0].length == words[i].length) {
                  cats[j].push(words[i]);
                  continue out;
              }
          cats.push([words[i]]);
      }
      function quote(word) {
          return JSON.stringify(word).replace(/[\u2028\u2029]/g, function(s) {
              switch (s) {
                  case "\u2028": return "\\u2028";
                  case "\u2029": return "\\u2029";
              }
              return s;
          });
      }
      function compareTo(arr) {
          if (arr.length == 1) return f += "return str === " + quote(arr[0]) + ";";
          f += "switch(str){";
          for (var i = 0; i < arr.length; ++i) f += "case " + quote(arr[i]) + ":";
          f += "return true}return false;";
      }
      // When there are more than three length categories, an outer
      // switch first dispatches on the lengths, to save on comparisons.
      if (cats.length > 3) {
          cats.sort(function(a, b) {return b.length - a.length;});
          f += "switch(str.length){";
          for (var i = 0; i < cats.length; ++i) {
              var cat = cats[i];
              f += "case " + cat[0].length + ":";
              compareTo(cat);
          }
          f += "}";
          // Otherwise, simply generate a flat `switch` statement.
      } else {
          compareTo(words);
      }
      return new Function("str", f);
  }
595516
def word_fts(self, word):
        
        return list(map(self.fts, self.segs(word)))
54646
function (nBytes) {
            var words = [];
            for (var i = 0; i < nBytes; i += 4) {
                words.push((Math.random() * 0x100000000) | 0);
            }

            return new WordArray.init(words, nBytes);
        }
930611
function _fetchWordList(path, callback) {
    var words = [];

    axios.get(path)
    .then(function(response) {

      var jsonData = response.data;

      if(response.responseType === 'text') {
        jsonData = JSON.parse(jsonData);
      }

      if(Array.isArray(jsonData.words)) {
        words = jsonData.words;
      }

      callback(words);
    }.bind(this))
    .catch(function(error) {
      callback(words);
    }.bind(this));
  }
348891
def build(self, words):
        """"""
        words = [self._normalize(tokens) for tokens in words]
        self._dawg = dawg.CompletionDAWG(words)
        self._loaded_model = True
24767
public static void addDict(Collection<String> words, String pos) {
		for(String w:words){
			dict.add(w, pos);
		}
		setDict();
	}
71533
function splitWord (word) {
  Util.assert(word);

  if (word.length < MAX_SAMPLE_SIZE) {
    return [word];
  }

  let chunks = [];
  for (let ii = 0; ii < word.length - MAX_SAMPLE_SIZE + 1; ++ii) {
    chunks.push(word.substring(ii, ii + MAX_SAMPLE_SIZE));
  }
  return chunks;
}
1040857
@SuppressWarnings("unchecked")
    @Nonnull
    protected Word<I> concatInternal(Word<? extends I>... words) {
        if (words.length == 0) {
            return this;
        }

        int len = length();

        int totalSize = len;
        for (Word<? extends I> word : words) {
            totalSize += word.length();
        }

        Object[] array = new Object[totalSize];
        writeToArray(0, array, 0, len);
        int currOfs = len;
        for (Word<? extends I> w : words) {
            int wLen = w.length();
            w.writeToArray(0, array, currOfs, wLen);
            currOfs += wLen;
        }

        return new SharedWord<>(array);
    }
649291
private List<String> getCorrectWords(List<String> wordsOrPhrases) {
    List<String> result = new ArrayList<>();
    for (String wordOrPhrase : wordsOrPhrases) {
      // this might be a phrase like "aufgrund dessen", so it needs to be split: 
      String[] words = tokenizeText(wordOrPhrase);
      boolean wordIsOkay = true;
      for (String word : words) {
        if (hunspellDict.misspelled(word)) {
          wordIsOkay = false;
          break;
        }
      }
      if (wordIsOkay) {
        result.add(wordOrPhrase);
      }
    }
    return result;
  }
1288358
function(config) {
    if (!config) {
      return [];
    }

    var files = grunt.file.expand(config);

    if (files.length) {
      return files;
    }

    return [config];
  }