I'm surprised this question doesn't come up more often. It's a tricky issue, and one that is highly open to interpretation.
Disclaimer: I am not a lawyer.
There is not a lot of specific guidance on this issue, but a well-researched overview of the topic was published by The International Free and Open Source Software Law Review, titled "Open source licensing notices in Web applications."
On that page, the author (Arnoud Engelfriet) discusses different means of satisfying license clauses for open source licenses, and some consequences if it's not done correctly. With respect to the MIT license and its requirement to be displayed, Engelfriet has this to say:
The author draws this conclusion:
He ends the article by providing sample text for a possible short form and long form attribution notice, to be included in the file header.
Based on this article and on other Stack Exchange questions about the same subject, I would say (in my non-lawyerly opinion) that if you can reasonably accommodate it, the first option you listed in your question is the best one. However, if you went with option #2, you would probably be fine, as it seems others have taken that same route.