Package dev.karlkadak.backend.config
Class WebConfig
java.lang.Object
dev.karlkadak.backend.config.WebConfig
- All Implemented Interfaces:
org.springframework.web.servlet.config.annotation.WebMvcConfigurer
@Configuration
public class WebConfig
extends Object
implements org.springframework.web.servlet.config.annotation.WebMvcConfigurer
Configuration class to set up global CORS settings, ensures the backend application allows cross-origin requests from
the React frontend
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionorg.springframework.web.servlet.config.annotation.WebMvcConfigurer
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.springframework.web.servlet.config.annotation.WebMvcConfigurer
addArgumentResolvers, addCorsMappings, addFormatters, addInterceptors, addResourceHandlers, addReturnValueHandlers, addViewControllers, configureAsyncSupport, configureContentNegotiation, configureDefaultServletHandling, configureHandlerExceptionResolvers, configureMessageConverters, configurePathMatch, configureViewResolvers, extendHandlerExceptionResolvers, extendMessageConverters, getMessageCodesResolver, getValidator
-
Constructor Details
-
WebConfig
public WebConfig()
-
-
Method Details
-
corsConfigurer
@Bean public org.springframework.web.servlet.config.annotation.WebMvcConfigurer corsConfigurer()
-