Skip to main content

Interface: StorageMeta

Additional configuration related to Storage related fields

Properties#

acceptedFiles#

Optional acceptedFiles: string[]

File MIME types that can be uploaded to this reference

Defined in#

models/properties.ts:608


fileName#

Optional fileName: (context: UploadedFileContext) => string

You can use this callback to customize the uploaded filename

param

Type declaration#

▸ (context): string

Parameters#
NameType
contextUploadedFileContext
Returns#

string

Defined in#

models/properties.ts:621


mediaType#

Optional mediaType: MediaType

Media type of this reference, used for displaying the preview

Defined in#

models/properties.ts:598


metadata#

Optional metadata: any

Specific metadata set in your uploaded file. For the default Firebase implementation, the values passed here are of type firebase.storage.UploadMetadata

Defined in#

models/properties.ts:615


postProcess#

Optional postProcess: (pathOrUrl: string) => Promise<string>

Post process the path

Type declaration#

▸ (pathOrUrl): Promise<string>

Parameters#
NameType
pathOrUrlstring
Returns#

Promise<string>

Defined in#

models/properties.ts:635


storagePath#

storagePath: string | (context: UploadedFileContext) => string

Absolute path in your bucket. You can specify it directly or use a callback

Defined in#

models/properties.ts:603


storeUrl#

Optional storeUrl: boolean

When set to true, this flag indicates that the download URL of the file will be saved in the datasource instead of the Cloud storage path. Note that the generated URL may use a token that, if disabled, may make the URL unusable and lose the original reference to Cloud Storage, so it is not encouraged to use this flag. Defaults to false

Defined in#

models/properties.ts:630