Skip to content

Commit b83b8c6

Browse files
committed
Updated documentation for compat
1 parent d38eced commit b83b8c6

File tree

2 files changed

+33
-0
lines changed

2 files changed

+33
-0
lines changed

packages/database-compat/src/api/Database.ts

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,9 +52,23 @@ export class Database implements FirebaseService, Compat<ModularDatabase> {
5252
*/
5353
constructor(readonly _delegate: ModularDatabase, readonly app: FirebaseApp) {}
5454

55+
/**
56+
* INTERNAL methods for internal-use only (tests, etc.).
57+
*
58+
* @const
59+
*/
5560
INTERNAL = {
61+
/**
62+
* Deletes a database
63+
*/
5664
delete: () => this._delegate._delete(),
65+
/**
66+
* Forces realtime database to use websockets over longpolling
67+
*/
5768
forceWebSockets,
69+
/**
70+
* Forces realtime database to use longpolling over websockets
71+
*/
5872
forceLongPolling
5973
};
6074

packages/firebase/compat/index.d.ts

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6018,6 +6018,25 @@ declare namespace firebase.database {
60186018
* ```
60196019
*/
60206020
app: firebase.app.App;
6021+
/**
6022+
* INTERNAL methods for internal-use only (tests, etc.).
6023+
*
6024+
* @const
6025+
*/
6026+
INTERNAL: {
6027+
/**
6028+
* Deletes a database
6029+
*/
6030+
delete: () => Promise<void>,
6031+
/**
6032+
* Force the use of websockets instead of longPolling.
6033+
*/
6034+
forceWebSockets: () => void,
6035+
/**
6036+
* Force the use of longPolling instead of websockets. This will be ignored if websocket protocol is used in databaseURL.
6037+
*/
6038+
forceLongPolling: () => void
6039+
};
60216040
/**
60226041
* Modify this instance to communicate with the Realtime Database emulator.
60236042
*

0 commit comments

Comments
 (0)