You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

30 lines
561 B

3 years ago
  1. /**
  2. * 默认的全局配置
  3. */
  4. export default {
  5. baseURL: '',
  6. header: {},
  7. method: 'GET',
  8. dataType: 'json',
  9. // #ifndef MP-ALIPAY
  10. responseType: 'text',
  11. // #endif
  12. custom: {},
  13. // #ifdef H5 || APP-PLUS || MP-ALIPAY || MP-WEIXIN
  14. timeout: 60000,
  15. // #endif
  16. // #ifdef APP-PLUS
  17. sslVerify: true,
  18. // #endif
  19. // #ifdef H5
  20. withCredentials: false,
  21. // #endif
  22. // #ifdef APP-PLUS
  23. firstIpv4: false,
  24. // #endif
  25. validateStatus: function validateStatus(status) {
  26. return status >= 200 && status < 300
  27. }
  28. }