Socket
Socket
Sign inDemoInstall

@firebase/app-compat

Package Overview
Dependencies
Maintainers
5
Versions
1148
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@firebase/app-compat - npm Package Compare versions

Comparing version 0.0.900-exp.6d640284e to 0.0.900-exp.725ab4684

dist/index.lite.esm5.js

58

dist/index.cjs.js

@@ -54,17 +54,16 @@ 'use strict';

var FirebaseAppImpl = /** @class */ (function () {
function FirebaseAppImpl(app, firebase) {
function FirebaseAppImpl(_delegate, firebase) {
var _this = this;
this.app = app;
this._delegate = _delegate;
this.firebase = firebase;
// add itself to container
// TODO: change the component name to 'app-compat' before the official release
modularAPIs._addComponent(app, new component.Component('app', function () { return _this; }, "PUBLIC" /* PUBLIC */));
this.container = app.container;
modularAPIs._addComponent(_delegate, new component.Component('app-compat', function () { return _this; }, "PUBLIC" /* PUBLIC */));
this.container = _delegate.container;
}
Object.defineProperty(FirebaseAppImpl.prototype, "automaticDataCollectionEnabled", {
get: function () {
return this.app.automaticDataCollectionEnabled;
return this._delegate.automaticDataCollectionEnabled;
},
set: function (val) {
this.app.automaticDataCollectionEnabled = val;
this._delegate.automaticDataCollectionEnabled = val;
},

@@ -76,3 +75,3 @@ enumerable: false,

get: function () {
return this.app.name;
return this._delegate.name;
},

@@ -84,3 +83,3 @@ enumerable: false,

get: function () {
return this.app.options;
return this._delegate.options;
},

@@ -93,7 +92,7 @@ enumerable: false,

return new Promise(function (resolve) {
_this.app.checkDestroyed();
_this._delegate.checkDestroyed();
resolve();
}).then(function () {
_this.firebase.INTERNAL.removeApp(_this.name);
return modularAPIs.deleteApp(_this.app);
return modularAPIs.deleteApp(_this._delegate);
});

@@ -116,6 +115,13 @@ };

FirebaseAppImpl.prototype._getService = function (name, instanceIdentifier) {
var _a;
if (instanceIdentifier === void 0) { instanceIdentifier = modularAPIs._DEFAULT_ENTRY_NAME; }
this.app.checkDestroyed();
this._delegate.checkDestroyed();
// Initialize instance if InstatiationMode is `EXPLICIT`.
var provider = this._delegate.container.getProvider(name);
if (!provider.isInitialized() &&
((_a = provider.getComponent()) === null || _a === void 0 ? void 0 : _a.instantiationMode) === "EXPLICIT" /* EXPLICIT */) {
provider.initialize();
}
// getImmediate will always succeed because _getService is only called for registered components.
return this.app.container.getProvider(name).getImmediate({
return provider.getImmediate({
identifier: instanceIdentifier

@@ -136,3 +142,3 @@ });

if (instanceIdentifier === void 0) { instanceIdentifier = modularAPIs._DEFAULT_ENTRY_NAME; }
this.app.container
this._delegate.container
// eslint-disable-next-line @typescript-eslint/no-explicit-any

@@ -147,7 +153,14 @@ .getProvider(name)

FirebaseAppImpl.prototype._addComponent = function (component) {
modularAPIs._addComponent(this.app, component);
modularAPIs._addComponent(this._delegate, component);
};
FirebaseAppImpl.prototype._addOrOverwriteComponent = function (component) {
modularAPIs._addOrOverwriteComponent(this.app, component);
modularAPIs._addOrOverwriteComponent(this._delegate, component);
};
FirebaseAppImpl.prototype.toJSON = function () {
return {
name: this.name,
automaticDataCollectionEnabled: this.automaticDataCollectionEnabled,
options: this.options
};
};
return FirebaseAppImpl;

@@ -290,2 +303,3 @@ }());

var componentName = component.name;
var componentNameWithoutCompat = componentName.replace('-compat', '');
if (modularAPIs._registerComponent(component) &&

@@ -298,3 +312,3 @@ component.type === "PUBLIC" /* PUBLIC */) {

// eslint-disable-next-line @typescript-eslint/no-explicit-any
if (typeof appArg[componentName] !== 'function') {
if (typeof appArg[componentNameWithoutCompat] !== 'function') {
// Invalid argument.

@@ -308,3 +322,3 @@ // This happens in the following case: firebase.storage('gs:/')

// eslint-disable-next-line @typescript-eslint/no-explicit-any
return appArg[componentName]();
return appArg[componentNameWithoutCompat]();
};

@@ -316,6 +330,6 @@ // ... and a container for service-level properties.

// eslint-disable-next-line @typescript-eslint/no-explicit-any
namespace[componentName] = serviceNamespace;
namespace[componentNameWithoutCompat] = serviceNamespace;
// Patch the FirebaseAppImpl prototype
// eslint-disable-next-line @typescript-eslint/no-explicit-any
firebaseAppImpl.prototype[componentName] =
firebaseAppImpl.prototype[componentNameWithoutCompat] =
// TODO: The eslint disable can be removed and the 'ignoreRestArgs'

@@ -335,3 +349,3 @@ // option added to the no-explicit-any rule when ESlint releases it.

? // eslint-disable-next-line @typescript-eslint/no-explicit-any
namespace[componentName]
namespace[componentNameWithoutCompat]
: null;

@@ -412,3 +426,3 @@ }

var name = "@firebase/app-compat";
var version = "0.0.900-exp.6d640284e";
var version = "0.0.900-exp.725ab4684";

@@ -415,0 +429,0 @@ /**

@@ -28,29 +28,28 @@ import { ErrorFactory, contains, deepExtend, createSubscribe, isBrowser } from '@firebase/util';

class FirebaseAppImpl {
constructor(app, firebase) {
this.app = app;
constructor(_delegate, firebase) {
this._delegate = _delegate;
this.firebase = firebase;
// add itself to container
// TODO: change the component name to 'app-compat' before the official release
_addComponent(app, new Component('app', () => this, "PUBLIC" /* PUBLIC */));
this.container = app.container;
_addComponent(_delegate, new Component('app-compat', () => this, "PUBLIC" /* PUBLIC */));
this.container = _delegate.container;
}
get automaticDataCollectionEnabled() {
return this.app.automaticDataCollectionEnabled;
return this._delegate.automaticDataCollectionEnabled;
}
set automaticDataCollectionEnabled(val) {
this.app.automaticDataCollectionEnabled = val;
this._delegate.automaticDataCollectionEnabled = val;
}
get name() {
return this.app.name;
return this._delegate.name;
}
get options() {
return this.app.options;
return this._delegate.options;
}
delete() {
return new Promise(resolve => {
this.app.checkDestroyed();
this._delegate.checkDestroyed();
resolve();
}).then(() => {
this.firebase.INTERNAL.removeApp(this.name);
return deleteApp(this.app);
return deleteApp(this._delegate);
});

@@ -73,5 +72,12 @@ }

_getService(name, instanceIdentifier = _DEFAULT_ENTRY_NAME) {
this.app.checkDestroyed();
var _a;
this._delegate.checkDestroyed();
// Initialize instance if InstatiationMode is `EXPLICIT`.
const provider = this._delegate.container.getProvider(name);
if (!provider.isInitialized() &&
((_a = provider.getComponent()) === null || _a === void 0 ? void 0 : _a.instantiationMode) === "EXPLICIT" /* EXPLICIT */) {
provider.initialize();
}
// getImmediate will always succeed because _getService is only called for registered components.
return this.app.container.getProvider(name).getImmediate({
return provider.getImmediate({
identifier: instanceIdentifier

@@ -91,3 +97,3 @@ });

_removeServiceInstance(name, instanceIdentifier = _DEFAULT_ENTRY_NAME) {
this.app.container
this._delegate.container
// eslint-disable-next-line @typescript-eslint/no-explicit-any

@@ -102,7 +108,14 @@ .getProvider(name)

_addComponent(component) {
_addComponent(this.app, component);
_addComponent(this._delegate, component);
}
_addOrOverwriteComponent(component) {
_addOrOverwriteComponent(this.app, component);
_addOrOverwriteComponent(this._delegate, component);
}
toJSON() {
return {
name: this.name,
automaticDataCollectionEnabled: this.automaticDataCollectionEnabled,
options: this.options
};
}
}

@@ -242,2 +255,3 @@ // TODO: investigate why the following needs to be commented out

const componentName = component.name;
const componentNameWithoutCompat = componentName.replace('-compat', '');
if (_registerComponent(component) &&

@@ -249,3 +263,3 @@ component.type === "PUBLIC" /* PUBLIC */) {

// eslint-disable-next-line @typescript-eslint/no-explicit-any
if (typeof appArg[componentName] !== 'function') {
if (typeof appArg[componentNameWithoutCompat] !== 'function') {
// Invalid argument.

@@ -259,3 +273,3 @@ // This happens in the following case: firebase.storage('gs:/')

// eslint-disable-next-line @typescript-eslint/no-explicit-any
return appArg[componentName]();
return appArg[componentNameWithoutCompat]();
};

@@ -267,6 +281,6 @@ // ... and a container for service-level properties.

// eslint-disable-next-line @typescript-eslint/no-explicit-any
namespace[componentName] = serviceNamespace;
namespace[componentNameWithoutCompat] = serviceNamespace;
// Patch the FirebaseAppImpl prototype
// eslint-disable-next-line @typescript-eslint/no-explicit-any
firebaseAppImpl.prototype[componentName] =
firebaseAppImpl.prototype[componentNameWithoutCompat] =
// TODO: The eslint disable can be removed and the 'ignoreRestArgs'

@@ -282,3 +296,3 @@ // option added to the no-explicit-any rule when ESlint releases it.

? // eslint-disable-next-line @typescript-eslint/no-explicit-any
namespace[componentName]
namespace[componentNameWithoutCompat]
: null;

@@ -359,3 +373,3 @@ }

const name = "@firebase/app-compat";
const version = "0.0.900-exp.6d640284e";
const version = "0.0.900-exp.725ab4684";

@@ -362,0 +376,0 @@ /**

@@ -29,17 +29,16 @@ import { ErrorFactory, contains, deepExtend, createSubscribe, isBrowser } from '@firebase/util';

var FirebaseAppImpl = /** @class */ (function () {
function FirebaseAppImpl(app, firebase) {
function FirebaseAppImpl(_delegate, firebase) {
var _this = this;
this.app = app;
this._delegate = _delegate;
this.firebase = firebase;
// add itself to container
// TODO: change the component name to 'app-compat' before the official release
_addComponent(app, new Component('app', function () { return _this; }, "PUBLIC" /* PUBLIC */));
this.container = app.container;
_addComponent(_delegate, new Component('app-compat', function () { return _this; }, "PUBLIC" /* PUBLIC */));
this.container = _delegate.container;
}
Object.defineProperty(FirebaseAppImpl.prototype, "automaticDataCollectionEnabled", {
get: function () {
return this.app.automaticDataCollectionEnabled;
return this._delegate.automaticDataCollectionEnabled;
},
set: function (val) {
this.app.automaticDataCollectionEnabled = val;
this._delegate.automaticDataCollectionEnabled = val;
},

@@ -51,3 +50,3 @@ enumerable: false,

get: function () {
return this.app.name;
return this._delegate.name;
},

@@ -59,3 +58,3 @@ enumerable: false,

get: function () {
return this.app.options;
return this._delegate.options;
},

@@ -68,7 +67,7 @@ enumerable: false,

return new Promise(function (resolve) {
_this.app.checkDestroyed();
_this._delegate.checkDestroyed();
resolve();
}).then(function () {
_this.firebase.INTERNAL.removeApp(_this.name);
return deleteApp(_this.app);
return deleteApp(_this._delegate);
});

@@ -91,6 +90,13 @@ };

FirebaseAppImpl.prototype._getService = function (name, instanceIdentifier) {
var _a;
if (instanceIdentifier === void 0) { instanceIdentifier = _DEFAULT_ENTRY_NAME; }
this.app.checkDestroyed();
this._delegate.checkDestroyed();
// Initialize instance if InstatiationMode is `EXPLICIT`.
var provider = this._delegate.container.getProvider(name);
if (!provider.isInitialized() &&
((_a = provider.getComponent()) === null || _a === void 0 ? void 0 : _a.instantiationMode) === "EXPLICIT" /* EXPLICIT */) {
provider.initialize();
}
// getImmediate will always succeed because _getService is only called for registered components.
return this.app.container.getProvider(name).getImmediate({
return provider.getImmediate({
identifier: instanceIdentifier

@@ -111,3 +117,3 @@ });

if (instanceIdentifier === void 0) { instanceIdentifier = _DEFAULT_ENTRY_NAME; }
this.app.container
this._delegate.container
// eslint-disable-next-line @typescript-eslint/no-explicit-any

@@ -122,7 +128,14 @@ .getProvider(name)

FirebaseAppImpl.prototype._addComponent = function (component) {
_addComponent(this.app, component);
_addComponent(this._delegate, component);
};
FirebaseAppImpl.prototype._addOrOverwriteComponent = function (component) {
_addOrOverwriteComponent(this.app, component);
_addOrOverwriteComponent(this._delegate, component);
};
FirebaseAppImpl.prototype.toJSON = function () {
return {
name: this.name,
automaticDataCollectionEnabled: this.automaticDataCollectionEnabled,
options: this.options
};
};
return FirebaseAppImpl;

@@ -265,2 +278,3 @@ }());

var componentName = component.name;
var componentNameWithoutCompat = componentName.replace('-compat', '');
if (_registerComponent(component) &&

@@ -273,3 +287,3 @@ component.type === "PUBLIC" /* PUBLIC */) {

// eslint-disable-next-line @typescript-eslint/no-explicit-any
if (typeof appArg[componentName] !== 'function') {
if (typeof appArg[componentNameWithoutCompat] !== 'function') {
// Invalid argument.

@@ -283,3 +297,3 @@ // This happens in the following case: firebase.storage('gs:/')

// eslint-disable-next-line @typescript-eslint/no-explicit-any
return appArg[componentName]();
return appArg[componentNameWithoutCompat]();
};

@@ -291,6 +305,6 @@ // ... and a container for service-level properties.

// eslint-disable-next-line @typescript-eslint/no-explicit-any
namespace[componentName] = serviceNamespace;
namespace[componentNameWithoutCompat] = serviceNamespace;
// Patch the FirebaseAppImpl prototype
// eslint-disable-next-line @typescript-eslint/no-explicit-any
firebaseAppImpl.prototype[componentName] =
firebaseAppImpl.prototype[componentNameWithoutCompat] =
// TODO: The eslint disable can be removed and the 'ignoreRestArgs'

@@ -310,3 +324,3 @@ // option added to the no-explicit-any rule when ESlint releases it.

? // eslint-disable-next-line @typescript-eslint/no-explicit-any
namespace[componentName]
namespace[componentNameWithoutCompat]
: null;

@@ -387,3 +401,3 @@ }

var name = "@firebase/app-compat";
var version = "0.0.900-exp.6d640284e";
var version = "0.0.900-exp.725ab4684";

@@ -390,0 +404,0 @@ /**

import * as modularAPIs from '@firebase/app';
import { deleteApp, _addComponent, _DEFAULT_ENTRY_NAME, registerVersion, setLogLevel, onLog, SDK_VERSION, initializeApp, _registerComponent } from '@firebase/app';
import { _addComponent, deleteApp, _DEFAULT_ENTRY_NAME, registerVersion, setLogLevel, onLog, SDK_VERSION, initializeApp, _registerComponent } from '@firebase/app';
import { Component } from '@firebase/component';

@@ -26,38 +26,25 @@ import { ErrorFactory, contains, deepExtend } from '@firebase/util';

*/
var FirebaseAppLiteImpl = /** @class */ (function () {
function FirebaseAppLiteImpl(app, firebase) {
var _this = this;
this.app = app;
class FirebaseAppLiteImpl {
constructor(_delegate, firebase) {
this._delegate = _delegate;
this.firebase = firebase;
// add itself to container
_addComponent(app, new Component('app', function () { return _this; }, "PUBLIC" /* PUBLIC */));
_addComponent(_delegate, new Component('app-compat', () => this, "PUBLIC" /* PUBLIC */));
}
Object.defineProperty(FirebaseAppLiteImpl.prototype, "automaticDataCollectionEnabled", {
get: function () {
return this.app.automaticDataCollectionEnabled;
},
set: function (val) {
this.automaticDataCollectionEnabled = val;
},
enumerable: false,
configurable: true
});
Object.defineProperty(FirebaseAppLiteImpl.prototype, "name", {
get: function () {
return this.app.name;
},
enumerable: false,
configurable: true
});
Object.defineProperty(FirebaseAppLiteImpl.prototype, "options", {
get: function () {
return this.app.options;
},
enumerable: false,
configurable: true
});
FirebaseAppLiteImpl.prototype.delete = function () {
get automaticDataCollectionEnabled() {
return this._delegate.automaticDataCollectionEnabled;
}
set automaticDataCollectionEnabled(val) {
this.automaticDataCollectionEnabled = val;
}
get name() {
return this._delegate.name;
}
get options() {
return this._delegate.options;
}
delete() {
this.firebase.INTERNAL.removeApp(this.name);
return deleteApp(this.app);
};
return deleteApp(this._delegate);
}
/**

@@ -77,12 +64,10 @@ * Return a service instance associated with this app (creating it

*/
FirebaseAppLiteImpl.prototype._getService = function (name, instanceIdentifier) {
if (instanceIdentifier === void 0) { instanceIdentifier = _DEFAULT_ENTRY_NAME; }
this.app.checkDestroyed();
_getService(name, instanceIdentifier = _DEFAULT_ENTRY_NAME) {
this._delegate.checkDestroyed();
// getImmediate will always succeed because _getService is only called for registered components.
return this.app.container.getProvider(name).getImmediate({
return this._delegate.container.getProvider(name).getImmediate({
identifier: instanceIdentifier
});
};
return FirebaseAppLiteImpl;
}());
}
}

@@ -105,10 +90,9 @@ /**

*/
var _a;
var ERRORS = (_a = {},
_a["no-app" /* NO_APP */] = "No Firebase App '{$appName}' has been created - " +
const ERRORS = {
["no-app" /* NO_APP */]: "No Firebase App '{$appName}' has been created - " +
'call Firebase App.initializeApp()',
_a["invalid-app-argument" /* INVALID_APP_ARGUMENT */] = 'firebase.{$appName}() takes either no argument or a ' +
'Firebase App instance.',
_a);
var ERROR_FACTORY = new ErrorFactory('app-compat', 'Firebase', ERRORS);
["invalid-app-argument" /* INVALID_APP_ARGUMENT */]: 'firebase.{$appName}() takes either no argument or a ' +
'Firebase App instance.'
};
const ERROR_FACTORY = new ErrorFactory('app-compat', 'Firebase', ERRORS);

@@ -139,7 +123,7 @@ /**

function createFirebaseNamespaceCore(firebaseAppImpl) {
var apps = {};
const apps = {};
// // eslint-disable-next-line @typescript-eslint/no-explicit-any
// const components = new Map<string, Component<any>>();
// A namespace is a plain JavaScript Object.
var namespace = {
const namespace = {
// Hack to prevent Babel from modifying the object returned

@@ -151,3 +135,3 @@ // as the firebase namespace.

// @ts-ignore
app: app,
app,
registerVersion: registerVersion,

@@ -161,5 +145,5 @@ setLogLevel: setLogLevel,

registerComponent: registerComponentCompat,
removeApp: removeApp,
useAsService: useAsService,
modularAPIs: modularAPIs
removeApp,
useAsService,
modularAPIs
}

@@ -205,6 +189,5 @@ };

*/
function initializeAppCompat(options, rawConfig) {
if (rawConfig === void 0) { rawConfig = {}; }
var app = initializeApp(options, rawConfig);
var appCompat = new firebaseAppImpl(app, namespace);
function initializeAppCompat(options, rawConfig = {}) {
const app = initializeApp(options, rawConfig);
const appCompat = new firebaseAppImpl(app, namespace);
apps[app.name] = appCompat;

@@ -218,6 +201,7 @@ return appCompat;

// Make a copy so caller cannot mutate the apps list.
return Object.keys(apps).map(function (name) { return apps[name]; });
return Object.keys(apps).map(name => apps[name]);
}
function registerComponentCompat(component) {
var componentName = component.name;
const componentName = component.name;
const componentNameWithoutCompat = componentName.replace('-compat', '');
if (_registerComponent(component) &&

@@ -227,6 +211,5 @@ component.type === "PUBLIC" /* PUBLIC */) {

// The Service namespace is an accessor function ...
var serviceNamespace = function (appArg) {
if (appArg === void 0) { appArg = app(); }
const serviceNamespace = (appArg = app()) => {
// eslint-disable-next-line @typescript-eslint/no-explicit-any
if (typeof appArg[componentName] !== 'function') {
if (typeof appArg[componentNameWithoutCompat] !== 'function') {
// Invalid argument.

@@ -240,3 +223,3 @@ // This happens in the following case: firebase.storage('gs:/')

// eslint-disable-next-line @typescript-eslint/no-explicit-any
return appArg[componentName]();
return appArg[componentNameWithoutCompat]();
};

@@ -248,15 +231,11 @@ // ... and a container for service-level properties.

// eslint-disable-next-line @typescript-eslint/no-explicit-any
namespace[componentName] = serviceNamespace;
namespace[componentNameWithoutCompat] = serviceNamespace;
// Patch the FirebaseAppImpl prototype
// eslint-disable-next-line @typescript-eslint/no-explicit-any
firebaseAppImpl.prototype[componentName] =
firebaseAppImpl.prototype[componentNameWithoutCompat] =
// TODO: The eslint disable can be removed and the 'ignoreRestArgs'
// option added to the no-explicit-any rule when ESlint releases it.
// eslint-disable-next-line @typescript-eslint/no-explicit-any
function () {
var args = [];
for (var _i = 0; _i < arguments.length; _i++) {
args[_i] = arguments[_i];
}
var serviceFxn = this._getService.bind(this, componentName);
function (...args) {
const serviceFxn = this._getService.bind(this, componentName);
return serviceFxn.apply(this, component.multipleInstances ? args : []);

@@ -267,3 +246,3 @@ };

? // eslint-disable-next-line @typescript-eslint/no-explicit-any
namespace[componentName]
namespace[componentNameWithoutCompat]
: null;

@@ -277,3 +256,3 @@ }

}
var useService = name;
const useService = name;
return useService;

@@ -301,6 +280,5 @@ }

function createFirebaseNamespaceLite() {
var namespace = createFirebaseNamespaceCore(FirebaseAppLiteImpl);
namespace.SDK_VERSION = namespace.SDK_VERSION + "_LITE";
var registerComponent = namespace.INTERNAL
.registerComponent;
const namespace = createFirebaseNamespaceCore(FirebaseAppLiteImpl);
namespace.SDK_VERSION = `${namespace.SDK_VERSION}_LITE`;
const registerComponent = namespace.INTERNAL.registerComponent;
namespace.INTERNAL.registerComponent = registerComponentForLite;

@@ -316,5 +294,5 @@ /**

if (component.type === "PUBLIC" /* PUBLIC */ &&
component.name !== 'performance' &&
component.name !== 'installations') {
throw Error(name + " cannot register with the standalone perf instance");
!component.name.includes('performance') &&
!component.name.includes('installations')) {
throw Error(`${name} cannot register with the standalone perf instance`);
}

@@ -326,4 +304,4 @@ return registerComponent(component);

var name$1 = "@firebase/app-compat";
var version = "0.0.900-exp.6d640284e";
const name$1 = "@firebase/app-compat";
const version = "0.0.900-exp.725ab4684";

@@ -367,3 +345,3 @@ /**

*/
var firebase = createFirebaseNamespaceLite();
const firebase = createFirebaseNamespaceLite();
registerCoreComponents('lite');

@@ -370,0 +348,0 @@

@@ -17,6 +17,26 @@ /**

*/
import { FirebaseApp, FirebaseOptions } from '@firebase/app-types';
import { _FirebaseNamespace, FirebaseService } from '@firebase/app-types/private';
import { FirebaseOptions } from './public-types';
import { Component } from '@firebase/component';
import { _FirebaseAppInternal } from "@firebase/app-types";
import { _FirebaseAppInternal as _FirebaseAppExp } from "@firebase/app";
import { _FirebaseService, _FirebaseNamespace } from './types';
import { Compat } from '@firebase/util';
export interface _FirebaseApp {
/**
* The (read-only) name (identifier) for this App. '[DEFAULT]' is the default
* App.
*/
name: string;
/**
* The (read-only) configuration options from the app initialization.
*/
options: FirebaseOptions;
/**
* The settable config flag for GDPR opt-in/opt-out
*/
automaticDataCollectionEnabled: boolean;
/**
* Make the given App unusable and free resources.
*/
delete(): Promise<void>;
}
/**

@@ -26,7 +46,7 @@ * Global context object for a collection of services using

*/
export declare class FirebaseAppImpl implements FirebaseApp {
private readonly app;
export declare class FirebaseAppImpl implements Compat<_FirebaseAppExp>, _FirebaseApp {
readonly _delegate: _FirebaseAppExp;
private readonly firebase;
private readonly container;
constructor(app: _FirebaseAppInternal, firebase: _FirebaseNamespace);
private container;
constructor(_delegate: _FirebaseAppExp, firebase: _FirebaseNamespace);
get automaticDataCollectionEnabled(): boolean;

@@ -51,3 +71,3 @@ set automaticDataCollectionEnabled(val: boolean);

*/
_getService(name: string, instanceIdentifier?: string): FirebaseService;
_getService(name: string, instanceIdentifier?: string): _FirebaseService;
/**

@@ -70,2 +90,3 @@ * Remove a service instance from the cache, so we will create a new instance for this service

_addOrOverwriteComponent(component: Component): void;
toJSON(): object;
}

@@ -17,3 +17,3 @@ /**

*/
import { FirebaseNamespace } from '@firebase/app-types';
import { FirebaseNamespace } from './public-types';
/**

@@ -20,0 +20,0 @@ * Return a firebase namespace object.

@@ -17,3 +17,3 @@ /**

*/
import { FirebaseNamespace } from '@firebase/app-types';
import { _FirebaseNamespace } from './types';
import { FirebaseAppImpl } from './firebaseApp';

@@ -28,2 +28,2 @@ import { FirebaseAppLiteImpl } from './lite/firebaseAppLite';

*/
export declare function createFirebaseNamespaceCore(firebaseAppImpl: typeof FirebaseAppImpl | typeof FirebaseAppLiteImpl): FirebaseNamespace;
export declare function createFirebaseNamespaceCore(firebaseAppImpl: typeof FirebaseAppImpl | typeof FirebaseAppLiteImpl): _FirebaseNamespace;

@@ -17,4 +17,6 @@ /**

*/
import { FirebaseNamespace } from '@firebase/app-types';
import { FirebaseNamespace } from './public-types';
export declare const firebase: FirebaseNamespace;
export default firebase;
export { _FirebaseNamespace, _FirebaseService } from './types';
export { FirebaseApp, FirebaseNamespace } from './public-types';

@@ -17,3 +17,3 @@ /**

*/
export declare const firebase: import("@firebase/app-types").FirebaseNamespace;
export declare const firebase: import("./public-types").FirebaseNamespace;
export default firebase;

@@ -17,5 +17,6 @@ /**

*/
import { FirebaseApp, FirebaseOptions } from '@firebase/app-types';
import { _FirebaseNamespace, FirebaseService } from '@firebase/app-types/private';
import { _FirebaseAppInternal } from "@firebase/app-types";
import { FirebaseApp, FirebaseOptions } from '../public-types';
import { _FirebaseNamespace, _FirebaseService } from '../types';
import { _FirebaseAppInternal as FirebaseAppExp } from "@firebase/app";
import { Compat } from '@firebase/util';
/**

@@ -25,6 +26,6 @@ * Global context object for a collection of services using

*/
export declare class FirebaseAppLiteImpl implements FirebaseApp {
private readonly app;
export declare class FirebaseAppLiteImpl implements FirebaseApp, Compat<FirebaseAppExp> {
readonly _delegate: FirebaseAppExp;
private readonly firebase;
constructor(app: _FirebaseAppInternal, firebase: _FirebaseNamespace);
constructor(_delegate: FirebaseAppExp, firebase: _FirebaseNamespace);
get automaticDataCollectionEnabled(): boolean;

@@ -49,3 +50,3 @@ set automaticDataCollectionEnabled(val: boolean);

*/
_getService(name: string, instanceIdentifier?: string): FirebaseService;
_getService(name: string, instanceIdentifier?: string): _FirebaseService;
}

@@ -17,3 +17,3 @@ /**

*/
import { FirebaseNamespace } from '@firebase/app-types';
import { FirebaseNamespace } from '../public-types';
export declare function createFirebaseNamespaceLite(): FirebaseNamespace;

@@ -17,8 +17,9 @@ /**

*/
import { FirebaseService } from '@firebase/app-types/private';
import { FirebaseApp } from '@firebase/app-types';
import { _FirebaseService } from '../src/types';
import { FirebaseApp } from '../src/public-types';
import { ComponentType, Component } from '@firebase/component';
export declare class TestService implements FirebaseService {
export declare class TestService implements _FirebaseService {
private app_;
instanceIdentifier?: string | undefined;
readonly _delegate: {};
constructor(app_: FirebaseApp, instanceIdentifier?: string | undefined);

@@ -25,0 +26,0 @@ get app(): FirebaseApp;

{
"name": "@firebase/app-compat",
"version": "0.0.900-exp.6d640284e",
"version": "0.0.900-exp.725ab4684",
"description": "The primary entrypoint to the Firebase JS SDK",

@@ -8,7 +8,6 @@ "author": "Firebase <firebase-support@google.com> (https://firebase.google.com/)",

"main": "dist/index.cjs.js",
"browser": "dist/index.esm5.js",
"module": "dist/index.esm5.js",
"esm2017": "dist/index.esm2017.js",
"browser": "dist/index.esm2017.js",
"module": "dist/index.esm2017.js",
"lite": "dist/index.lite.js",
"lite-esm2017": "dist/index.lite.esm2017.js",
"lite-esm5": "dist/index.lite.esm5.js",
"files": [

@@ -29,12 +28,11 @@ "dist"

"test:browser:debug": "karma start --browsers Chrome --auto-watch",
"test:node": "TS_NODE_FILES=true TS_NODE_CACHE=NO TS_NODE_COMPILER_OPTIONS='{\"module\":\"commonjs\"}' nyc --reporter lcovonly -- mocha test/**/*.test.* src/**/*.test.ts --config ../../config/mocharc.node.js",
"prepare": "yarn build:release"
"test:node": "TS_NODE_FILES=true TS_NODE_CACHE=NO TS_NODE_COMPILER_OPTIONS='{\"module\":\"commonjs\"}' nyc --reporter lcovonly -- mocha test/**/*.test.* src/**/*.test.ts --config ../../config/mocharc.node.js"
},
"license": "Apache-2.0",
"dependencies": {
"@firebase/app": "0.0.900-exp.6d640284e",
"@firebase/util": "0.3.4",
"@firebase/app": "0.0.900-exp.725ab4684",
"@firebase/util": "1.1.0",
"@firebase/logger": "0.2.6",
"@firebase/component": "0.1.21",
"tslib": "^1.11.1",
"@firebase/component": "0.5.2",
"tslib": "^2.1.0",
"dom-storage": "2.1.0",

@@ -44,7 +42,7 @@ "xmlhttprequest": "1.8.0"

"devDependencies": {
"rollup": "2.33.2",
"rollup": "2.35.1",
"@rollup/plugin-json": "4.1.0",
"rollup-plugin-replace": "2.2.0",
"rollup-plugin-typescript2": "0.29.0",
"typescript": "4.0.5"
"typescript": "4.2.2"
},

@@ -66,3 +64,4 @@ "repository": {

},
"esm5": "dist/index.esm5.js",
"peerDependencies": {}
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc