S

Shyam Dubey • 3.70K Points
Extraordinary

Q. How can you define a custom error page in Spring Boot?

  • (A) Create a file named error.html in /resources/templates
  • (B) Define it in application.properties
  • (C) Add @CustomErrorPage annotation
  • (D) Define error.xml in resources
  • Correct Answer - Option(A)
  • Views: 10
  • Filed under category Springboot
  • Hashtags:

Explanation by: Shyam Dubey
Spring Boot automatically maps error.html in /templates as a custom error page.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.