@firebase/storage 0.12.6 → 0.13.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.browser.cjs.js +4 -20
- package/dist/index.browser.cjs.js.map +1 -1
- package/dist/index.cjs.js +4 -20
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm2017.js +4 -20
- package/dist/index.esm2017.js.map +1 -1
- package/dist/index.esm5.js +4 -20
- package/dist/index.esm5.js.map +1 -1
- package/dist/index.node.cjs.js +15 -33
- package/dist/index.node.cjs.js.map +1 -1
- package/dist/node-esm/index.node.esm.js +15 -33
- package/dist/node-esm/index.node.esm.js.map +1 -1
- package/dist/node-esm/src/api.browser.d.ts +1 -2
- package/dist/node-esm/src/api.d.ts +1 -1
- package/dist/node-esm/src/api.node.d.ts +1 -2
- package/dist/node-esm/src/implementation/connection.d.ts +2 -3
- package/dist/node-esm/src/platform/browser/connection.d.ts +1 -2
- package/dist/node-esm/src/platform/connection.d.ts +1 -2
- package/dist/node-esm/src/platform/node/connection.d.ts +5 -5
- package/dist/node-esm/src/public-types.d.ts +1 -1
- package/dist/node-esm/src/reference.d.ts +2 -3
- package/dist/src/api.browser.d.ts +1 -2
- package/dist/src/api.d.ts +1 -1
- package/dist/src/api.node.d.ts +1 -2
- package/dist/src/implementation/connection.d.ts +2 -3
- package/dist/src/platform/browser/connection.d.ts +1 -2
- package/dist/src/platform/connection.d.ts +1 -2
- package/dist/src/platform/node/connection.d.ts +5 -5
- package/dist/src/public-types.d.ts +1 -1
- package/dist/src/reference.d.ts +2 -3
- package/dist/storage-public.d.ts +3 -4
- package/dist/storage.d.ts +5 -7
- package/package.json +3 -3
|
@@ -14,7 +14,6 @@
|
|
|
14
14
|
* See the License for the specific language governing permissions and
|
|
15
15
|
* limitations under the License.
|
|
16
16
|
*/
|
|
17
|
-
/// <reference types="node" />
|
|
18
17
|
import { StorageReference } from './public-types';
|
|
19
18
|
/**
|
|
20
19
|
* Downloads the data at the object's location. Returns an error if the object
|
|
@@ -45,4 +44,4 @@ export declare function getBlob(ref: StorageReference, maxDownloadSizeBytes?: nu
|
|
|
45
44
|
* retrieve.
|
|
46
45
|
* @returns A stream with the object's data as bytes
|
|
47
46
|
*/
|
|
48
|
-
export declare function getStream(ref: StorageReference, maxDownloadSizeBytes?: number):
|
|
47
|
+
export declare function getStream(ref: StorageReference, maxDownloadSizeBytes?: number): ReadableStream;
|
|
@@ -82,7 +82,7 @@ export declare function uploadString(ref: StorageReference, value: string, forma
|
|
|
82
82
|
export declare function uploadBytesResumable(ref: StorageReference, data: Blob | Uint8Array | ArrayBuffer, metadata?: UploadMetadata): UploadTask;
|
|
83
83
|
/**
|
|
84
84
|
* A `Promise` that resolves with the metadata for this object. If this
|
|
85
|
-
* object doesn't exist or metadata cannot be
|
|
85
|
+
* object doesn't exist or metadata cannot be retrieved, the promise is
|
|
86
86
|
* rejected.
|
|
87
87
|
* @public
|
|
88
88
|
* @param ref - {@link StorageReference} to get metadata from.
|
|
@@ -14,7 +14,6 @@
|
|
|
14
14
|
* See the License for the specific language governing permissions and
|
|
15
15
|
* limitations under the License.
|
|
16
16
|
*/
|
|
17
|
-
/// <reference types="node" />
|
|
18
17
|
import { StorageReference } from './public-types';
|
|
19
18
|
/**
|
|
20
19
|
* Downloads the data at the object's location. Returns an error if the object
|
|
@@ -45,4 +44,4 @@ export declare function getBlob(ref: StorageReference, maxDownloadSizeBytes?: nu
|
|
|
45
44
|
* retrieve.
|
|
46
45
|
* @returns A stream with the object's data as bytes
|
|
47
46
|
*/
|
|
48
|
-
export declare function getStream(ref: StorageReference, maxDownloadSizeBytes?: number):
|
|
47
|
+
export declare function getStream(ref: StorageReference, maxDownloadSizeBytes?: number): ReadableStream;
|
|
@@ -14,11 +14,10 @@
|
|
|
14
14
|
* See the License for the specific language governing permissions and
|
|
15
15
|
* limitations under the License.
|
|
16
16
|
*/
|
|
17
|
-
/// <reference types="node" />
|
|
18
17
|
/** Network headers */
|
|
19
18
|
export declare type Headers = Record<string, string>;
|
|
20
19
|
/** Response type exposed by the networking APIs. */
|
|
21
|
-
export declare type ConnectionType = string | ArrayBuffer | Blob |
|
|
20
|
+
export declare type ConnectionType = string | ArrayBuffer | Blob | ReadableStream<Uint8Array>;
|
|
22
21
|
/**
|
|
23
22
|
* A lightweight wrapper around XMLHttpRequest with a
|
|
24
23
|
* goog.net.XhrIo-like interface.
|
|
@@ -48,7 +47,7 @@ export interface Connection<T extends ConnectionType> {
|
|
|
48
47
|
removeUploadProgressListener(listener: (p1: ProgressEvent) => void): void;
|
|
49
48
|
}
|
|
50
49
|
/**
|
|
51
|
-
* Error codes for requests made by the
|
|
50
|
+
* Error codes for requests made by the XhrIo wrapper.
|
|
52
51
|
*/
|
|
53
52
|
export declare enum ErrorCode {
|
|
54
53
|
NO_ERROR = 0,
|
|
@@ -14,7 +14,6 @@
|
|
|
14
14
|
* See the License for the specific language governing permissions and
|
|
15
15
|
* limitations under the License.
|
|
16
16
|
*/
|
|
17
|
-
/// <reference types="node" />
|
|
18
17
|
import { Connection, ConnectionType, ErrorCode, Headers } from '../../implementation/connection';
|
|
19
18
|
/**
|
|
20
19
|
* Network layer for browsers. We use this instead of goog.net.XhrIo because
|
|
@@ -51,6 +50,6 @@ export declare class XhrBlobConnection extends XhrConnection<Blob> {
|
|
|
51
50
|
initXhr(): void;
|
|
52
51
|
}
|
|
53
52
|
export declare function newBlobConnection(): Connection<Blob>;
|
|
54
|
-
export declare function newStreamConnection(): Connection<
|
|
53
|
+
export declare function newStreamConnection(): Connection<ReadableStream>;
|
|
55
54
|
export declare function injectTestConnection(factory: (() => Connection<string>) | null): void;
|
|
56
55
|
export {};
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
/// <reference types="node" />
|
|
2
1
|
/**
|
|
3
2
|
* @license
|
|
4
3
|
* Copyright 2020 Google LLC
|
|
@@ -20,4 +19,4 @@ export declare function injectTestConnection(factory: (() => Connection<string>)
|
|
|
20
19
|
export declare function newTextConnection(): Connection<string>;
|
|
21
20
|
export declare function newBytesConnection(): Connection<ArrayBuffer>;
|
|
22
21
|
export declare function newBlobConnection(): Connection<Blob>;
|
|
23
|
-
export declare function newStreamConnection(): Connection<
|
|
22
|
+
export declare function newStreamConnection(): Connection<ReadableStream<Uint8Array>>;
|
|
@@ -32,7 +32,7 @@ declare abstract class FetchConnection<T extends ConnectionType> implements Conn
|
|
|
32
32
|
protected sent_: boolean;
|
|
33
33
|
protected fetch_: typeof undiciFetch;
|
|
34
34
|
constructor();
|
|
35
|
-
send(url: string, method: string, body?: ArrayBufferView | Blob | string, headers?: Record<string, string>): Promise<void>;
|
|
35
|
+
send(url: string, method: string, body?: NodeJS.ArrayBufferView | Blob | string, headers?: Record<string, string>): Promise<void>;
|
|
36
36
|
getErrorCode(): ErrorCode;
|
|
37
37
|
getStatus(): number;
|
|
38
38
|
abstract getResponse(): T;
|
|
@@ -50,12 +50,12 @@ export declare class FetchBytesConnection extends FetchConnection<ArrayBuffer> {
|
|
|
50
50
|
getResponse(): ArrayBuffer;
|
|
51
51
|
}
|
|
52
52
|
export declare function newBytesConnection(): Connection<ArrayBuffer>;
|
|
53
|
-
export declare class FetchStreamConnection extends FetchConnection<
|
|
53
|
+
export declare class FetchStreamConnection extends FetchConnection<ReadableStream<Uint8Array>> {
|
|
54
54
|
private stream_;
|
|
55
|
-
send(url: string, method: string, body?: ArrayBufferView | Blob | string, headers?: Record<string, string>): Promise<void>;
|
|
56
|
-
getResponse():
|
|
55
|
+
send(url: string, method: string, body?: NodeJS.ArrayBufferView | Blob | string, headers?: Record<string, string>): Promise<void>;
|
|
56
|
+
getResponse(): ReadableStream;
|
|
57
57
|
}
|
|
58
|
-
export declare function newStreamConnection(): Connection<
|
|
58
|
+
export declare function newStreamConnection(): Connection<ReadableStream<Uint8Array>>;
|
|
59
59
|
export declare function newBlobConnection(): Connection<Blob>;
|
|
60
60
|
export declare function injectTestConnection(factory: (() => Connection<string>) | null): void;
|
|
61
61
|
export {};
|
|
@@ -14,7 +14,6 @@
|
|
|
14
14
|
* See the License for the specific language governing permissions and
|
|
15
15
|
* limitations under the License.
|
|
16
16
|
*/
|
|
17
|
-
/// <reference types="node" />
|
|
18
17
|
import { Location } from './implementation/location';
|
|
19
18
|
import { ListOptions, UploadResult } from './public-types';
|
|
20
19
|
import { StringFormat } from './implementation/string';
|
|
@@ -87,7 +86,7 @@ export declare function getBytesInternal(ref: Reference, maxDownloadSizeBytes?:
|
|
|
87
86
|
*/
|
|
88
87
|
export declare function getBlobInternal(ref: Reference, maxDownloadSizeBytes?: number): Promise<Blob>;
|
|
89
88
|
/** Stream the bytes at the object's location. */
|
|
90
|
-
export declare function getStreamInternal(ref: Reference, maxDownloadSizeBytes?: number):
|
|
89
|
+
export declare function getStreamInternal(ref: Reference, maxDownloadSizeBytes?: number): ReadableStream;
|
|
91
90
|
/**
|
|
92
91
|
* Uploads data to this object's location.
|
|
93
92
|
* The upload is not resumable.
|
|
@@ -164,7 +163,7 @@ export declare function listAll(ref: Reference): Promise<ListResult>;
|
|
|
164
163
|
export declare function list(ref: Reference, options?: ListOptions | null): Promise<ListResult>;
|
|
165
164
|
/**
|
|
166
165
|
* A `Promise` that resolves with the metadata for this object. If this
|
|
167
|
-
* object doesn't exist or metadata cannot be
|
|
166
|
+
* object doesn't exist or metadata cannot be retrieved, the promise is
|
|
168
167
|
* rejected.
|
|
169
168
|
* @public
|
|
170
169
|
* @param ref - StorageReference to get metadata from.
|
|
@@ -14,7 +14,6 @@
|
|
|
14
14
|
* See the License for the specific language governing permissions and
|
|
15
15
|
* limitations under the License.
|
|
16
16
|
*/
|
|
17
|
-
/// <reference types="node" />
|
|
18
17
|
import { StorageReference } from './public-types';
|
|
19
18
|
/**
|
|
20
19
|
* Downloads the data at the object's location. Returns an error if the object
|
|
@@ -45,4 +44,4 @@ export declare function getBlob(ref: StorageReference, maxDownloadSizeBytes?: nu
|
|
|
45
44
|
* retrieve.
|
|
46
45
|
* @returns A stream with the object's data as bytes
|
|
47
46
|
*/
|
|
48
|
-
export declare function getStream(ref: StorageReference, maxDownloadSizeBytes?: number):
|
|
47
|
+
export declare function getStream(ref: StorageReference, maxDownloadSizeBytes?: number): ReadableStream;
|
package/dist/src/api.d.ts
CHANGED
|
@@ -82,7 +82,7 @@ export declare function uploadString(ref: StorageReference, value: string, forma
|
|
|
82
82
|
export declare function uploadBytesResumable(ref: StorageReference, data: Blob | Uint8Array | ArrayBuffer, metadata?: UploadMetadata): UploadTask;
|
|
83
83
|
/**
|
|
84
84
|
* A `Promise` that resolves with the metadata for this object. If this
|
|
85
|
-
* object doesn't exist or metadata cannot be
|
|
85
|
+
* object doesn't exist or metadata cannot be retrieved, the promise is
|
|
86
86
|
* rejected.
|
|
87
87
|
* @public
|
|
88
88
|
* @param ref - {@link StorageReference} to get metadata from.
|
package/dist/src/api.node.d.ts
CHANGED
|
@@ -14,7 +14,6 @@
|
|
|
14
14
|
* See the License for the specific language governing permissions and
|
|
15
15
|
* limitations under the License.
|
|
16
16
|
*/
|
|
17
|
-
/// <reference types="node" />
|
|
18
17
|
import { StorageReference } from './public-types';
|
|
19
18
|
/**
|
|
20
19
|
* Downloads the data at the object's location. Returns an error if the object
|
|
@@ -45,4 +44,4 @@ export declare function getBlob(ref: StorageReference, maxDownloadSizeBytes?: nu
|
|
|
45
44
|
* retrieve.
|
|
46
45
|
* @returns A stream with the object's data as bytes
|
|
47
46
|
*/
|
|
48
|
-
export declare function getStream(ref: StorageReference, maxDownloadSizeBytes?: number):
|
|
47
|
+
export declare function getStream(ref: StorageReference, maxDownloadSizeBytes?: number): ReadableStream;
|
|
@@ -14,11 +14,10 @@
|
|
|
14
14
|
* See the License for the specific language governing permissions and
|
|
15
15
|
* limitations under the License.
|
|
16
16
|
*/
|
|
17
|
-
/// <reference types="node" />
|
|
18
17
|
/** Network headers */
|
|
19
18
|
export declare type Headers = Record<string, string>;
|
|
20
19
|
/** Response type exposed by the networking APIs. */
|
|
21
|
-
export declare type ConnectionType = string | ArrayBuffer | Blob |
|
|
20
|
+
export declare type ConnectionType = string | ArrayBuffer | Blob | ReadableStream<Uint8Array>;
|
|
22
21
|
/**
|
|
23
22
|
* A lightweight wrapper around XMLHttpRequest with a
|
|
24
23
|
* goog.net.XhrIo-like interface.
|
|
@@ -48,7 +47,7 @@ export interface Connection<T extends ConnectionType> {
|
|
|
48
47
|
removeUploadProgressListener(listener: (p1: ProgressEvent) => void): void;
|
|
49
48
|
}
|
|
50
49
|
/**
|
|
51
|
-
* Error codes for requests made by the
|
|
50
|
+
* Error codes for requests made by the XhrIo wrapper.
|
|
52
51
|
*/
|
|
53
52
|
export declare enum ErrorCode {
|
|
54
53
|
NO_ERROR = 0,
|
|
@@ -14,7 +14,6 @@
|
|
|
14
14
|
* See the License for the specific language governing permissions and
|
|
15
15
|
* limitations under the License.
|
|
16
16
|
*/
|
|
17
|
-
/// <reference types="node" />
|
|
18
17
|
import { Connection, ConnectionType, ErrorCode, Headers } from '../../implementation/connection';
|
|
19
18
|
/**
|
|
20
19
|
* Network layer for browsers. We use this instead of goog.net.XhrIo because
|
|
@@ -51,6 +50,6 @@ export declare class XhrBlobConnection extends XhrConnection<Blob> {
|
|
|
51
50
|
initXhr(): void;
|
|
52
51
|
}
|
|
53
52
|
export declare function newBlobConnection(): Connection<Blob>;
|
|
54
|
-
export declare function newStreamConnection(): Connection<
|
|
53
|
+
export declare function newStreamConnection(): Connection<ReadableStream>;
|
|
55
54
|
export declare function injectTestConnection(factory: (() => Connection<string>) | null): void;
|
|
56
55
|
export {};
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
/// <reference types="node" />
|
|
2
1
|
/**
|
|
3
2
|
* @license
|
|
4
3
|
* Copyright 2020 Google LLC
|
|
@@ -20,4 +19,4 @@ export declare function injectTestConnection(factory: (() => Connection<string>)
|
|
|
20
19
|
export declare function newTextConnection(): Connection<string>;
|
|
21
20
|
export declare function newBytesConnection(): Connection<ArrayBuffer>;
|
|
22
21
|
export declare function newBlobConnection(): Connection<Blob>;
|
|
23
|
-
export declare function newStreamConnection(): Connection<
|
|
22
|
+
export declare function newStreamConnection(): Connection<ReadableStream<Uint8Array>>;
|
|
@@ -32,7 +32,7 @@ declare abstract class FetchConnection<T extends ConnectionType> implements Conn
|
|
|
32
32
|
protected sent_: boolean;
|
|
33
33
|
protected fetch_: typeof undiciFetch;
|
|
34
34
|
constructor();
|
|
35
|
-
send(url: string, method: string, body?: ArrayBufferView | Blob | string, headers?: Record<string, string>): Promise<void>;
|
|
35
|
+
send(url: string, method: string, body?: NodeJS.ArrayBufferView | Blob | string, headers?: Record<string, string>): Promise<void>;
|
|
36
36
|
getErrorCode(): ErrorCode;
|
|
37
37
|
getStatus(): number;
|
|
38
38
|
abstract getResponse(): T;
|
|
@@ -50,12 +50,12 @@ export declare class FetchBytesConnection extends FetchConnection<ArrayBuffer> {
|
|
|
50
50
|
getResponse(): ArrayBuffer;
|
|
51
51
|
}
|
|
52
52
|
export declare function newBytesConnection(): Connection<ArrayBuffer>;
|
|
53
|
-
export declare class FetchStreamConnection extends FetchConnection<
|
|
53
|
+
export declare class FetchStreamConnection extends FetchConnection<ReadableStream<Uint8Array>> {
|
|
54
54
|
private stream_;
|
|
55
|
-
send(url: string, method: string, body?: ArrayBufferView | Blob | string, headers?: Record<string, string>): Promise<void>;
|
|
56
|
-
getResponse():
|
|
55
|
+
send(url: string, method: string, body?: NodeJS.ArrayBufferView | Blob | string, headers?: Record<string, string>): Promise<void>;
|
|
56
|
+
getResponse(): ReadableStream;
|
|
57
57
|
}
|
|
58
|
-
export declare function newStreamConnection(): Connection<
|
|
58
|
+
export declare function newStreamConnection(): Connection<ReadableStream<Uint8Array>>;
|
|
59
59
|
export declare function newBlobConnection(): Connection<Blob>;
|
|
60
60
|
export declare function injectTestConnection(factory: (() => Connection<string>) | null): void;
|
|
61
61
|
export {};
|
package/dist/src/reference.d.ts
CHANGED
|
@@ -14,7 +14,6 @@
|
|
|
14
14
|
* See the License for the specific language governing permissions and
|
|
15
15
|
* limitations under the License.
|
|
16
16
|
*/
|
|
17
|
-
/// <reference types="node" />
|
|
18
17
|
import { Location } from './implementation/location';
|
|
19
18
|
import { ListOptions, UploadResult } from './public-types';
|
|
20
19
|
import { StringFormat } from './implementation/string';
|
|
@@ -87,7 +86,7 @@ export declare function getBytesInternal(ref: Reference, maxDownloadSizeBytes?:
|
|
|
87
86
|
*/
|
|
88
87
|
export declare function getBlobInternal(ref: Reference, maxDownloadSizeBytes?: number): Promise<Blob>;
|
|
89
88
|
/** Stream the bytes at the object's location. */
|
|
90
|
-
export declare function getStreamInternal(ref: Reference, maxDownloadSizeBytes?: number):
|
|
89
|
+
export declare function getStreamInternal(ref: Reference, maxDownloadSizeBytes?: number): ReadableStream;
|
|
91
90
|
/**
|
|
92
91
|
* Uploads data to this object's location.
|
|
93
92
|
* The upload is not resumable.
|
|
@@ -164,7 +163,7 @@ export declare function listAll(ref: Reference): Promise<ListResult>;
|
|
|
164
163
|
export declare function list(ref: Reference, options?: ListOptions | null): Promise<ListResult>;
|
|
165
164
|
/**
|
|
166
165
|
* A `Promise` that resolves with the metadata for this object. If this
|
|
167
|
-
* object doesn't exist or metadata cannot be
|
|
166
|
+
* object doesn't exist or metadata cannot be retrieved, the promise is
|
|
168
167
|
* rejected.
|
|
169
168
|
* @public
|
|
170
169
|
* @param ref - StorageReference to get metadata from.
|
package/dist/storage-public.d.ts
CHANGED
|
@@ -3,7 +3,6 @@
|
|
|
3
3
|
*
|
|
4
4
|
* @packageDocumentation
|
|
5
5
|
*/
|
|
6
|
-
/// <reference types="node" />
|
|
7
6
|
import { CompleteFn , EmulatorMockTokenOptions , FirebaseError , NextFn , Subscribe , Unsubscribe } from '@firebase/util';
|
|
8
7
|
import { FirebaseApp } from '@firebase/app';
|
|
9
8
|
/**
|
|
@@ -91,7 +90,7 @@ export declare interface FullMetadata extends UploadMetadata {
|
|
|
91
90
|
*/
|
|
92
91
|
updated: string;
|
|
93
92
|
/**
|
|
94
|
-
* Tokens to allow access to the
|
|
93
|
+
* Tokens to allow access to the download URL.
|
|
95
94
|
*/
|
|
96
95
|
downloadTokens: string[] | undefined;
|
|
97
96
|
/**
|
|
@@ -142,7 +141,7 @@ export declare function getBytes(ref: StorageReference, maxDownloadSizeBytes?: n
|
|
|
142
141
|
export declare function getDownloadURL(ref: StorageReference): Promise<string>;
|
|
143
142
|
/**
|
|
144
143
|
* A `Promise` that resolves with the metadata for this object. If this
|
|
145
|
-
* object doesn't exist or metadata cannot be
|
|
144
|
+
* object doesn't exist or metadata cannot be retrieved, the promise is
|
|
146
145
|
* rejected.
|
|
147
146
|
* @public
|
|
148
147
|
* @param ref - {@link StorageReference} to get metadata from.
|
|
@@ -169,7 +168,7 @@ export declare function getStorage(app?: FirebaseApp, bucketUrl?: string): Fireb
|
|
|
169
168
|
* retrieve.
|
|
170
169
|
* @returns A stream with the object's data as bytes
|
|
171
170
|
*/
|
|
172
|
-
export declare function getStream(ref: StorageReference, maxDownloadSizeBytes?: number):
|
|
171
|
+
export declare function getStream(ref: StorageReference, maxDownloadSizeBytes?: number): ReadableStream;
|
|
173
172
|
/* Excluded from this release type: _invalidArgument */
|
|
174
173
|
/* Excluded from this release type: _invalidRootOperation */
|
|
175
174
|
/**
|
package/dist/storage.d.ts
CHANGED
|
@@ -4,7 +4,6 @@
|
|
|
4
4
|
* @packageDocumentation
|
|
5
5
|
*/
|
|
6
6
|
|
|
7
|
-
/// <reference types="node" />
|
|
8
7
|
import { AppCheckInternalComponentName } from '@firebase/app-check-interop-types';
|
|
9
8
|
import { CompleteFn } from '@firebase/util';
|
|
10
9
|
import { EmulatorMockTokenOptions } from '@firebase/util';
|
|
@@ -52,7 +51,7 @@ declare interface Connection<T extends ConnectionType> {
|
|
|
52
51
|
}
|
|
53
52
|
|
|
54
53
|
/** Response type exposed by the networking APIs. */
|
|
55
|
-
declare type ConnectionType = string | ArrayBuffer | Blob |
|
|
54
|
+
declare type ConnectionType = string | ArrayBuffer | Blob | ReadableStream<Uint8Array>;
|
|
56
55
|
|
|
57
56
|
/**
|
|
58
57
|
* Modify this {@link FirebaseStorage} instance to communicate with the Cloud Storage emulator.
|
|
@@ -83,7 +82,7 @@ export declare function deleteObject(ref: StorageReference): Promise<void>;
|
|
|
83
82
|
export { EmulatorMockTokenOptions }
|
|
84
83
|
|
|
85
84
|
/**
|
|
86
|
-
* Error codes for requests made by the
|
|
85
|
+
* Error codes for requests made by the XhrIo wrapper.
|
|
87
86
|
*/
|
|
88
87
|
declare enum ErrorCode {
|
|
89
88
|
NO_ERROR = 0,
|
|
@@ -280,7 +279,7 @@ export declare interface FullMetadata extends UploadMetadata {
|
|
|
280
279
|
*/
|
|
281
280
|
updated: string;
|
|
282
281
|
/**
|
|
283
|
-
* Tokens to allow access to the
|
|
282
|
+
* Tokens to allow access to the download URL.
|
|
284
283
|
*/
|
|
285
284
|
downloadTokens: string[] | undefined;
|
|
286
285
|
/**
|
|
@@ -339,7 +338,7 @@ export declare function getDownloadURL(ref: StorageReference): Promise<string>;
|
|
|
339
338
|
|
|
340
339
|
/**
|
|
341
340
|
* A `Promise` that resolves with the metadata for this object. If this
|
|
342
|
-
* object doesn't exist or metadata cannot be
|
|
341
|
+
* object doesn't exist or metadata cannot be retrieved, the promise is
|
|
343
342
|
* rejected.
|
|
344
343
|
* @public
|
|
345
344
|
* @param ref - {@link StorageReference} to get metadata from.
|
|
@@ -368,7 +367,7 @@ export declare function getStorage(app?: FirebaseApp, bucketUrl?: string): Fireb
|
|
|
368
367
|
* retrieve.
|
|
369
368
|
* @returns A stream with the object's data as bytes
|
|
370
369
|
*/
|
|
371
|
-
export declare function getStream(ref: StorageReference, maxDownloadSizeBytes?: number):
|
|
370
|
+
export declare function getStream(ref: StorageReference, maxDownloadSizeBytes?: number): ReadableStream;
|
|
372
371
|
|
|
373
372
|
/**
|
|
374
373
|
* @license
|
|
@@ -386,7 +385,6 @@ export declare function getStream(ref: StorageReference, maxDownloadSizeBytes?:
|
|
|
386
385
|
* See the License for the specific language governing permissions and
|
|
387
386
|
* limitations under the License.
|
|
388
387
|
*/
|
|
389
|
-
/// <reference types="node" />
|
|
390
388
|
/** Network headers */
|
|
391
389
|
declare type Headers_2 = Record<string, string>;
|
|
392
390
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@firebase/storage",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.13.0",
|
|
4
4
|
"description": "",
|
|
5
5
|
"author": "Firebase <firebase-support@google.com> (https://firebase.google.com/)",
|
|
6
6
|
"main": "dist/index.node.cjs.js",
|
|
@@ -56,8 +56,8 @@
|
|
|
56
56
|
"@firebase/app": "0.x"
|
|
57
57
|
},
|
|
58
58
|
"devDependencies": {
|
|
59
|
-
"@firebase/app": "0.10.
|
|
60
|
-
"@firebase/auth": "1.7.
|
|
59
|
+
"@firebase/app": "0.10.9",
|
|
60
|
+
"@firebase/auth": "1.7.7",
|
|
61
61
|
"rollup": "2.79.1",
|
|
62
62
|
"@rollup/plugin-alias": "5.1.0",
|
|
63
63
|
"@rollup/plugin-json": "4.1.0",
|