@firebase/database 0.13.6 → 0.13.7
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/CHANGELOG.md +10 -0
- package/dist/index.esm2017.js +9 -3
- package/dist/index.esm2017.js.map +1 -1
- package/dist/index.esm5.js +9 -19
- package/dist/index.esm5.js.map +1 -1
- package/dist/index.node.cjs.js +8 -18
- package/dist/index.node.cjs.js.map +1 -1
- package/dist/index.standalone.js +0 -16
- package/dist/index.standalone.js.map +1 -1
- package/dist/node-esm/index.node.esm.js +9 -3
- package/dist/node-esm/index.node.esm.js.map +1 -1
- package/package.json +4 -4
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import Websocket from 'faye-websocket';
|
|
2
|
-
import { stringify, jsonEval, contains, assert, isNodeSdk, base64, stringToByteArray, Sha1, deepCopy, base64Encode, isMobileCordova, stringLength, Deferred, safeGet, isAdmin, isValidFormat, isEmpty, isReactNative, assertionError, map, querystring, errorPrefix, getModularInstance, createMockUserToken } from '@firebase/util';
|
|
2
|
+
import { stringify, jsonEval, contains, assert, isNodeSdk, base64, stringToByteArray, Sha1, deepCopy, base64Encode, isMobileCordova, stringLength, Deferred, safeGet, isAdmin, isValidFormat, isEmpty, isReactNative, assertionError, map, querystring, errorPrefix, getModularInstance, getDefaultEmulatorHost, createMockUserToken } from '@firebase/util';
|
|
3
3
|
import { Logger, LogLevel } from '@firebase/logger';
|
|
4
4
|
import { getApp, _getProvider, SDK_VERSION as SDK_VERSION$1, _registerComponent, registerVersion } from '@firebase/app';
|
|
5
5
|
import { Component } from '@firebase/component';
|
|
@@ -1250,7 +1250,7 @@ WebSocketConnection.responsesRequiredToBeHealthy = 2;
|
|
|
1250
1250
|
WebSocketConnection.healthyTimeout = 30000;
|
|
1251
1251
|
|
|
1252
1252
|
const name = "@firebase/database";
|
|
1253
|
-
const version = "0.13.
|
|
1253
|
+
const version = "0.13.7";
|
|
1254
1254
|
|
|
1255
1255
|
/**
|
|
1256
1256
|
* @license
|
|
@@ -13705,9 +13705,15 @@ function forceLongPolling() {
|
|
|
13705
13705
|
* @returns The `Database` instance of the provided app.
|
|
13706
13706
|
*/
|
|
13707
13707
|
function getDatabase(app = getApp(), url) {
|
|
13708
|
-
|
|
13708
|
+
const db = _getProvider(app, 'database').getImmediate({
|
|
13709
13709
|
identifier: url
|
|
13710
13710
|
});
|
|
13711
|
+
const databaseEmulatorHost = getDefaultEmulatorHost('database');
|
|
13712
|
+
if (databaseEmulatorHost) {
|
|
13713
|
+
const [host, port] = databaseEmulatorHost.split(':');
|
|
13714
|
+
connectDatabaseEmulator(db, host, parseInt(port, 10));
|
|
13715
|
+
}
|
|
13716
|
+
return db;
|
|
13711
13717
|
}
|
|
13712
13718
|
/**
|
|
13713
13719
|
* Modify the provided instance to communicate with the Realtime Database
|