#Vercel BLOB adapter installed but uploads still going to local directory

5 messages · Page 1 of 1 (latest)

warm elm
#

plugins: [
vercelBlobStorage({
enabled: true,
collections: {
[(Media.slug, Users.slug)]: true,
},
token: EnvServer.BLOB_READ_WRITE_TOKEN,
}),
],

import type { CollectionConfig } from 'payload'

export const Media: CollectionConfig = {
slug: 'media',
upload: {
imageSizes: [
{
name: 'thumbnail',
width: 400,
height: undefined,
position: 'centre',
},
{
name: 'card',
width: 768,
height: undefined,
position: 'centre',
},
{
name: 'tablet',
width: 1024,
height: undefined,
position: 'centre',
},
],
adminThumbnail: 'thumbnail',
mimeTypes: ['image/*'],
},
fields: [
{
name: 'alt',
type: 'text',
},
],
}

Uploading the file on the dev server uploads the file to the media folder and vercel blob is empty.

brittle groveBOT
eternal pumice
#

Invalid configuration, not sure why TypeScript isn't yelling at you

#

If you want multiple, you'd do

media: true
users: true