1
0
mirror of https://github.com/badges/shields.git synced 2025-04-18 19:44:04 +03:00

cache some badges for longer (#9785)

This commit is contained in:
chris48s 2023-12-06 18:42:06 +00:00 committed by GitHub
parent 45bb786147
commit 57820b2eb9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 7 additions and 5 deletions

View File

@ -65,6 +65,8 @@ export default class Bundlephobia extends BaseJsonService {
},
]
static _cacheLength = 900
static defaultBadgeData = { label: 'bundlephobia', color: 'informational' }
static render({ format, size }) {

View File

@ -49,7 +49,7 @@ export default class Discord extends BaseJsonService {
},
}
static _cacheLength = 60
static _cacheLength = 300
static defaultBadgeData = { label: 'chat' }

View File

@ -16,7 +16,7 @@ export default class OpencollectiveAll extends OpencollectiveBase {
},
}
static _cacheLength = 1800
static _cacheLength = 3600
static defaultBadgeData = {
label: 'backers and sponsors',

View File

@ -16,7 +16,7 @@ export default class OpencollectiveBackers extends OpencollectiveBase {
},
}
static _cacheLength = 1800
static _cacheLength = 3600
static defaultBadgeData = {
label: 'backers',

View File

@ -16,7 +16,7 @@ export default class OpencollectiveSponsors extends OpencollectiveBase {
},
}
static _cacheLength = 1800
static _cacheLength = 3600
static defaultBadgeData = {
label: 'sponsors',

View File

@ -53,7 +53,7 @@ export default class PypiDownloads extends BaseJsonService {
},
]
static _cacheLength = 21600
static _cacheLength = 28800
static defaultBadgeData = { label: 'downloads' }