Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

staticURL seems unintentionally deprecated #7028

Closed
makunoia opened this issue Jul 4, 2024 · 1 comment
Closed

staticURL seems unintentionally deprecated #7028

makunoia opened this issue Jul 4, 2024 · 1 comment
Labels

Comments

@makunoia
Copy link

makunoia commented Jul 4, 2024

Link to reproduction

No response

Payload Version

3.0.0-beta.55

Node Version

v20.14.0

Next.js Version

Next.js 15 RC

Describe the Bug

staticURL key is not accepted by TypeScript in the upload object,

Reproduction Steps

  1. Create a project with Payload v3.0.0-beta.55
  2. Create a new Collection with the upload object
  3. Add staticURL key

This gives a typescript error:
Object literal may only specify known properties, and 'staticURL' does not exist in type 'UploadConfig'

Adapters and Plugins

No response

@makunoia makunoia added status: needs-triage Possible bug which hasn't been reproduced yet v3 labels Jul 4, 2024
@paulpopus
Copy link
Contributor

Static URL has been deprecated, in the case of using an adapter you can set a generateFileURL function instead https://payloadcms.com/docs/beta/upload/storage-adapters#collection-specific-options

Otherwise in the API request the media item will have a url string for fetching the file itself.

@github-actions github-actions bot removed the status: needs-triage Possible bug which hasn't been reproduced yet label Jul 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants