It's literally impossible for a reader to memorize the visual configuration of every word. You don't have to memorize every word. One of the most critical skills in reading is to bring the words off the page very rapidly. That's another mechanical skill. The longer it takes someone to recognize word patterns and decode them, the less energy available to relate what they've just read to what they already know.
Comprehension entails comparison.
As you read, you bring the vocabulary off the page in its textual format and compare whatever is being said to what you already know. If you don't have the background knowledge, comprehension is very difficult. For example, if you're reading a physics text and you're not a physicist, even though you can decode the words and bring them off the page, it's not going to mean very much to you, because you don't have the vocabulary understanding and experience with the concepts. We now have a very clear understanding that reading is not a natural process. If it were, we wouldn't have so many youngsters having difficulty learning to read, and we also would have more cultures on this planet with a written language as well as an oral language.