Made wordList directive more generic