@firebase/storage-types

  • Version 0.4.1
  • Published
  • 5.77 kB
  • No dependencies
  • Apache-2.0 license

Install

npm i @firebase/storage-types
yarn add @firebase/storage-types
pnpm add @firebase/storage-types

Overview

@firebase/storage Types

Index

Classes

class FirebaseStorage

class FirebaseStorage {}

    property app

    app: any;

      property maxOperationRetryTime

      maxOperationRetryTime: number;

        property maxUploadRetryTime

        maxUploadRetryTime: number;

          method ref

          ref: (path?: string) => Reference;

            method refFromURL

            refFromURL: (url: string) => Reference;

              method setMaxOperationRetryTime

              setMaxOperationRetryTime: (time: number) => void;

                method setMaxUploadRetryTime

                setMaxUploadRetryTime: (time: number) => void;

                  method useEmulator

                  useEmulator: (host: string, port: number) => void;

                    Interfaces

                    interface FirebaseStorageError

                    interface FirebaseStorageError extends FirebaseError {}

                      property serverResponse

                      serverResponse: string | null;

                        interface FullMetadata

                        interface FullMetadata extends UploadMetadata {}

                          property bucket

                          bucket: string;

                            property fullPath

                            fullPath: string;

                              property generation

                              generation: string;

                                property metageneration

                                metageneration: string;

                                  property name

                                  name: string;

                                    property size

                                    size: number;

                                      property timeCreated

                                      timeCreated: string;

                                        property updated

                                        updated: string;

                                          interface ListOptions

                                          interface ListOptions {}

                                            property maxResults

                                            maxResults?: number | null;

                                              property pageToken

                                              pageToken?: string | null;

                                                interface ListResult

                                                interface ListResult {}

                                                  property items

                                                  items: Reference[];

                                                    property nextPageToken

                                                    nextPageToken: string | null;

                                                      property prefixes

                                                      prefixes: Reference[];

                                                        interface Reference

                                                        interface Reference {}

                                                          property bucket

                                                          bucket: string;

                                                            property fullPath

                                                            fullPath: string;

                                                              property name

                                                              name: string;

                                                                property parent

                                                                parent: Reference | null;

                                                                  property root

                                                                  root: Reference;

                                                                    property storage

                                                                    storage: FirebaseStorage;

                                                                      method child

                                                                      child: (path: string) => Reference;

                                                                        method delete

                                                                        delete: () => Promise<void>;

                                                                          method getDownloadURL

                                                                          getDownloadURL: () => Promise<string>;

                                                                            method getMetadata

                                                                            getMetadata: () => Promise<FullMetadata>;

                                                                              method list

                                                                              list: (options?: ListOptions) => Promise<ListResult>;

                                                                                method listAll

                                                                                listAll: () => Promise<ListResult>;

                                                                                  method put

                                                                                  put: (
                                                                                  data: Blob | Uint8Array | ArrayBuffer,
                                                                                  metadata?: UploadMetadata
                                                                                  ) => UploadTask;

                                                                                    method putString

                                                                                    putString: (
                                                                                    data: string,
                                                                                    format?: StringFormat,
                                                                                    metadata?: UploadMetadata
                                                                                    ) => UploadTask;

                                                                                      method toString

                                                                                      toString: () => string;

                                                                                        method updateMetadata

                                                                                        updateMetadata: (metadata: SettableMetadata) => Promise<FullMetadata>;

                                                                                          interface SettableMetadata

                                                                                          interface SettableMetadata {}

                                                                                            property cacheControl

                                                                                            cacheControl?: string | null;

                                                                                              property contentDisposition

                                                                                              contentDisposition?: string | null;

                                                                                                property contentEncoding

                                                                                                contentEncoding?: string | null;

                                                                                                  property contentLanguage

                                                                                                  contentLanguage?: string | null;

                                                                                                    property contentType

                                                                                                    contentType?: string | null;

                                                                                                      property customMetadata

                                                                                                      customMetadata?: {
                                                                                                      [/* warning: coerced from ? */ key: string]: string;
                                                                                                      } | null;

                                                                                                        interface StorageObserver

                                                                                                        interface StorageObserver<T> {}

                                                                                                          property complete

                                                                                                          complete?: CompleteFn | null;

                                                                                                            property error

                                                                                                            error?: (error: FirebaseStorageError) => void | null;

                                                                                                              property next

                                                                                                              next?: NextFn<T> | null;

                                                                                                                interface UploadMetadata

                                                                                                                interface UploadMetadata extends SettableMetadata {}

                                                                                                                  property md5Hash

                                                                                                                  md5Hash?: string | null;

                                                                                                                    interface UploadTask

                                                                                                                    interface UploadTask {}

                                                                                                                      property snapshot

                                                                                                                      snapshot: UploadTaskSnapshot;

                                                                                                                        method cancel

                                                                                                                        cancel: () => boolean;

                                                                                                                          method catch

                                                                                                                          catch: (onRejected: (error: FirebaseStorageError) => any) => Promise<any>;

                                                                                                                            method on

                                                                                                                            on: (
                                                                                                                            event: TaskEvent,
                                                                                                                            nextOrObserver?:
                                                                                                                            | StorageObserver<UploadTaskSnapshot>
                                                                                                                            | ((snapshot: UploadTaskSnapshot) => any),
                                                                                                                            error?: (a: FirebaseStorageError) => any,
                                                                                                                            complete?: Unsubscribe | null
                                                                                                                            ) => Function;

                                                                                                                              method pause

                                                                                                                              pause: () => boolean;

                                                                                                                                method resume

                                                                                                                                resume: () => boolean;

                                                                                                                                  method then

                                                                                                                                  then: (
                                                                                                                                  onFulfilled?: (snapshot: UploadTaskSnapshot) => any,
                                                                                                                                  onRejected?: (error: FirebaseStorageError) => any
                                                                                                                                  ) => Promise<any>;

                                                                                                                                    interface UploadTaskSnapshot

                                                                                                                                    interface UploadTaskSnapshot {}

                                                                                                                                      property bytesTransferred

                                                                                                                                      bytesTransferred: number;

                                                                                                                                        property metadata

                                                                                                                                        metadata: FullMetadata;

                                                                                                                                          property ref

                                                                                                                                          ref: Reference;

                                                                                                                                            property state

                                                                                                                                            state: TaskState;

                                                                                                                                              property task

                                                                                                                                              task: UploadTask;

                                                                                                                                                property totalBytes

                                                                                                                                                totalBytes: number;

                                                                                                                                                  Type Aliases

                                                                                                                                                  type StringFormat

                                                                                                                                                  type StringFormat = string;

                                                                                                                                                    type TaskEvent

                                                                                                                                                    type TaskEvent = string;

                                                                                                                                                      type TaskState

                                                                                                                                                      type TaskState = string;

                                                                                                                                                        Package Files (1)

                                                                                                                                                        Dependencies (0)

                                                                                                                                                        No dependencies.

                                                                                                                                                        Dev Dependencies (1)

                                                                                                                                                        Peer Dependencies (2)

                                                                                                                                                        Badge

                                                                                                                                                        To add a badge like this onejsDocs.io badgeto your package's README, use the codes available below.

                                                                                                                                                        You may also use Shields.io to create a custom badge linking to https://www.jsdocs.io/package/@firebase/storage-types.

                                                                                                                                                        • Markdown
                                                                                                                                                          [![jsDocs.io](https://img.shields.io/badge/jsDocs.io-reference-blue)](https://www.jsdocs.io/package/@firebase/storage-types)
                                                                                                                                                        • HTML
                                                                                                                                                          <a href="https://www.jsdocs.io/package/@firebase/storage-types"><img src="https://img.shields.io/badge/jsDocs.io-reference-blue" alt="jsDocs.io"></a>