소스 검색

修改README跨域设置

Jia_RG 6 년 전
부모
커밋
110e27c965
1개의 변경된 파일7개의 추가작업 그리고 5개의 파일을 삭제
  1. 7 5
      hsweb-starter/hsweb-spring-boot-starter/README.md

+ 7 - 5
hsweb-starter/hsweb-spring-boot-starter/README.md

@@ -15,11 +15,13 @@ hsweb:
 hsweb: 
     cors:
       enable: true
-      allowed-headers: "*"
-      allowed-methods: "*"
-      allowed-origins: "*"
-      allow-credentials: true
-      max-age: 14400
+      configs:
+        - /**:
+            allowed-headers: "*"
+            allowed-methods: ["GET", "POST", "PUT", "PATCH", "DELETE", "OPTIONS"]
+            allowed-origins: ["http://xxx.example.com"]
+            allow-credentials: true
+            maxAge: 1800
 ```
 
 # json序列化配置