2
0

Add cache-control header on newly uploaded files

This commit is contained in:
Baptiste Arnaud
2023-11-01 15:42:53 +01:00
parent a5641811a3
commit d1502f8300
6 changed files with 6 additions and 3 deletions

View File

@ -31,6 +31,7 @@ export const UploadButton = ({
Object.entries(data.formData).forEach(([key, value]) => {
formData.append(key, value)
})
formData.append('Cache-Control', 'max-age=86400')
formData.append('file', file)
const upload = await fetch(data.presignedUrl, {
method: 'POST',