feat(图片缓存功能): 将生产环境的连接头也识别为oss图片进行缓存
This commit is contained in:
parent
5a064efb1f
commit
2af2a0ec4f
@ -209,9 +209,12 @@ class ImageCacheManager {
|
||||
return true
|
||||
}
|
||||
|
||||
// 新增:允许缓存特定域名下的资源
|
||||
// 允许缓存特定域名下的资源
|
||||
const ossBaseUrl = 'https://tkm-likei.oss-ap-southeast-1.aliyuncs.com/h5'
|
||||
if (url.startsWith(ossBaseUrl)) {
|
||||
// 允许缓存开发环境下的代理路径
|
||||
const devProxyPath = '/oss/h5/'
|
||||
|
||||
if (url.startsWith(ossBaseUrl) || url.startsWith(devProxyPath)) {
|
||||
return true
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user