I have a text file with all of the english nouns called words.txt. And my goal is to look for a word given by the user in this file. But since I'm new to javascript, I was hoping to find a way with which, in pure javascript, I can save this file into a variable in which i can later look for the word that has been input.
EDIT: I would like a pure javascript way to do this, so no jquery or ajax.
XMLHttpRequest. That IS JavaScript. Almost everything you can do with jQuery, you can do also with plain (I'm not using the word pure, as it is wrong) JavaScript, jQuery makes the things much easier and simpler. There is no solution for your question, if you want to limit yourself for some unknown reasons only to "pure" JavaScript.