Skip to main content

Static Resource Configuration

Learn Static Resource Configuration (Spring MVC Configuration, Spring MVC) with worked examples, diagrams and interview questions. Free on JavaSchoolLab.

Fresher Notes Static resources are files such as CSS, JS and images served directly without a controller, mapped through a ResourceHttpRequestHandler . Boot defaults serve /static , /public , /resources and /META-INF/resources from the classpath at the root URL. addResourceHandlers in WebMvcConfigurer maps a URL pattern to one or more locations such as classpath:/assets/ .

More lessons in Spring MVC Configuration