| | |
| | | import org.springframework.web.server.WebFilterChain; |
| | | import reactor.core.publisher.Mono; |
| | | |
| | | /** |
| | | * 跨域配置 |
| | | * |
| | | * @author se |
| | | * @date 2024-08-28 |
| | | */ |
| | | //@Configuration |
| | | @SuppressWarnings("ALL") |
| | | public class CorsConfig |
| | | { |
| | | /** |
| | | * 这里为支持的请求头,如果有自定义的header字段请自己添加 |
| | | */ |
| | | // private static final String ALLOWED_HEADERS = "X-Requested-With, Content-Type, Authorization, credential, X-XSRF-TOKEN, token, Admin-Token, App-Token" |
| | | private static final String ALLOWED_HEADERS = "*"; |
| | | private static final String ALLOWED_METHODS = "GET,POST,PUT,DELETE,OPTIONS,HEAD"; |