Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@firebase/app-compat

Package Overview
Dependencies
Maintainers
5
Versions
1205
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.800-exp.fe55004be to 0.0.900-exp.1b15844a1

82

dist/index.cjs.js

@@ -8,5 +8,27 @@ 'use strict';

var component = require('@firebase/component');
var app = require('@firebase/app');
var modularAPIs = require('@firebase/app');
var logger$1 = require('@firebase/logger');
function _interopNamespace(e) {
if (e && e.__esModule) return e;
var n = Object.create(null);
if (e) {
Object.keys(e).forEach(function (k) {
if (k !== 'default') {
var d = Object.getOwnPropertyDescriptor(e, k);
Object.defineProperty(n, k, d.get ? d : {
enumerable: true,
get: function () {
return e[k];
}
});
}
});
}
n['default'] = e;
return Object.freeze(n);
}
var modularAPIs__namespace = /*#__PURE__*/_interopNamespace(modularAPIs);
/**

@@ -33,10 +55,10 @@ * @license

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

@@ -74,3 +96,3 @@ Object.defineProperty(FirebaseAppImpl.prototype, "automaticDataCollectionEnabled", {

_this.firebase.INTERNAL.removeApp(_this.name);
return app.deleteApp(_this.app);
return modularAPIs.deleteApp(_this.app);
});

@@ -93,3 +115,3 @@ };

FirebaseAppImpl.prototype._getService = function (name, instanceIdentifier) {
if (instanceIdentifier === void 0) { instanceIdentifier = app._DEFAULT_ENTRY_NAME; }
if (instanceIdentifier === void 0) { instanceIdentifier = modularAPIs._DEFAULT_ENTRY_NAME; }
this.app.checkDestroyed();

@@ -112,3 +134,3 @@ // getImmediate will always succeed because _getService is only called for registered components.

FirebaseAppImpl.prototype._removeServiceInstance = function (name, instanceIdentifier) {
if (instanceIdentifier === void 0) { instanceIdentifier = app._DEFAULT_ENTRY_NAME; }
if (instanceIdentifier === void 0) { instanceIdentifier = modularAPIs._DEFAULT_ENTRY_NAME; }
this.app.container

@@ -124,7 +146,14 @@ // eslint-disable-next-line @typescript-eslint/no-explicit-any

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

@@ -199,13 +228,14 @@ }());

// @ts-ignore
app: app$1,
registerVersion: app.registerVersion,
setLogLevel: app.setLogLevel,
onLog: app.onLog,
app: app,
registerVersion: modularAPIs.registerVersion,
setLogLevel: modularAPIs.setLogLevel,
onLog: modularAPIs.onLog,
// @ts-ignore
apps: null,
SDK_VERSION: app.SDK_VERSION,
SDK_VERSION: modularAPIs.SDK_VERSION,
INTERNAL: {
registerComponent: registerComponentCompat,
removeApp: removeApp,
useAsService: useAsService
useAsService: useAsService,
modularAPIs: modularAPIs__namespace
}

@@ -239,4 +269,4 @@ };

*/
function app$1(name) {
name = name || app._DEFAULT_ENTRY_NAME;
function app(name) {
name = name || modularAPIs._DEFAULT_ENTRY_NAME;
if (!util.contains(apps, name)) {

@@ -248,3 +278,3 @@ throw ERROR_FACTORY.create("no-app" /* NO_APP */, { appName: name });

// @ts-ignore
app$1['App'] = firebaseAppImpl;
app['App'] = firebaseAppImpl;
/**

@@ -255,5 +285,5 @@ * Create a new App instance (name must be unique).

if (rawConfig === void 0) { rawConfig = {}; }
var app$1 = app.initializeApp(options, rawConfig);
var appCompat = new firebaseAppImpl(app$1, namespace);
apps[app$1.name] = appCompat;
var app = modularAPIs.initializeApp(options, rawConfig);
var appCompat = new firebaseAppImpl(app, namespace);
apps[app.name] = appCompat;
return appCompat;

@@ -270,3 +300,3 @@ }

var componentName = component.name;
if (app._registerComponent(component) &&
if (modularAPIs._registerComponent(component) &&
component.type === "PUBLIC" /* PUBLIC */) {

@@ -276,3 +306,3 @@ // create service namespace for public components

var serviceNamespace = function (appArg) {
if (appArg === void 0) { appArg = app$1(); }
if (appArg === void 0) { appArg = app(); }
// eslint-disable-next-line @typescript-eslint/no-explicit-any

@@ -389,3 +419,3 @@ if (typeof appArg[componentName] !== 'function') {

var name = "@firebase/app-compat";
var version = "0.0.800-exp.fe55004be";
var version = "0.0.900";

@@ -410,3 +440,3 @@ /**

// Register `app` package.
app.registerVersion(name, version, variant);
modularAPIs.registerVersion(name, version, variant);
}

@@ -413,0 +443,0 @@

import { ErrorFactory, contains, deepExtend, createSubscribe, isBrowser } from '@firebase/util';
import { Component } from '@firebase/component';
import * as modularAPIs from '@firebase/app';
import { _addComponent, deleteApp, _DEFAULT_ENTRY_NAME, _addOrOverwriteComponent, registerVersion, setLogLevel, onLog, SDK_VERSION, initializeApp, _registerComponent } from '@firebase/app';

@@ -103,2 +104,9 @@ import { Logger } from '@firebase/logger';

}
toJSON() {
return {
name: this.name,
automaticDataCollectionEnabled: this.automaticDataCollectionEnabled,
options: this.options
};
}
}

@@ -172,12 +180,13 @@ // TODO: investigate why the following needs to be commented out

app,
registerVersion,
setLogLevel,
onLog,
registerVersion: registerVersion,
setLogLevel: setLogLevel,
onLog: onLog,
// @ts-ignore
apps: null,
SDK_VERSION,
SDK_VERSION: SDK_VERSION,
INTERNAL: {
registerComponent: registerComponentCompat,
removeApp,
useAsService
useAsService,
modularAPIs
}

@@ -350,3 +359,3 @@ };

const name = "@firebase/app-compat";
const version = "0.0.800-exp.fe55004be";
const version = "0.0.900";

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

import { ErrorFactory, contains, deepExtend, createSubscribe, isBrowser } from '@firebase/util';
import { __assign } from 'tslib';
import { Component } from '@firebase/component';
import * as modularAPIs from '@firebase/app';
import { deleteApp, _addComponent, _addOrOverwriteComponent, _DEFAULT_ENTRY_NAME, registerVersion, setLogLevel, onLog, SDK_VERSION, initializeApp, _registerComponent } from '@firebase/app';

@@ -120,2 +121,9 @@ import { Logger } from '@firebase/logger';

};
FirebaseAppImpl.prototype.toJSON = function () {
return {
name: this.name,
automaticDataCollectionEnabled: this.automaticDataCollectionEnabled,
options: this.options
};
};
return FirebaseAppImpl;

@@ -200,3 +208,4 @@ }());

removeApp: removeApp,
useAsService: useAsService
useAsService: useAsService,
modularAPIs: modularAPIs
}

@@ -375,3 +384,3 @@ };

var name = "@firebase/app-compat";
var version = "0.0.800-exp.fe55004be";
var version = "0.0.900";

@@ -378,0 +387,0 @@ /**

@@ -0,1 +1,2 @@

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

@@ -131,12 +132,13 @@ import { Component } from '@firebase/component';

app,
registerVersion,
setLogLevel,
onLog,
registerVersion: registerVersion,
setLogLevel: setLogLevel,
onLog: onLog,
// @ts-ignore
apps: null,
SDK_VERSION,
SDK_VERSION: SDK_VERSION,
INTERNAL: {
registerComponent: registerComponentCompat,
removeApp,
useAsService
useAsService,
modularAPIs
}

@@ -289,3 +291,3 @@ };

const name$1 = "@firebase/app-compat";
const version = "0.0.800-exp.fe55004be";
const version = "0.0.900";

@@ -292,0 +294,0 @@ /**

@@ -0,1 +1,2 @@

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

@@ -156,3 +157,4 @@ import { Component } from '@firebase/component';

removeApp: removeApp,
useAsService: useAsService
useAsService: useAsService,
modularAPIs: modularAPIs
}

@@ -311,3 +313,3 @@ };

var name$1 = "@firebase/app-compat";
var version = "0.0.800-exp.fe55004be";
var version = "0.0.900";

@@ -314,0 +316,0 @@ /**

@@ -67,2 +67,3 @@ /**

_addOrOverwriteComponent(component: Component): void;
toJSON(): object;
}
{
"name": "@firebase/app-compat",
"version": "0.0.800-exp.fe55004be",
"version": "0.0.900-exp.1b15844a1",
"description": "The primary entrypoint to the Firebase JS SDK",

@@ -28,11 +28,10 @@ "author": "Firebase <firebase-support@google.com> (https://firebase.google.com/)",

"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.800-exp.fe55004be",
"@firebase/util": "0.3.2",
"@firebase/app": "0.0.900-exp.1b15844a1",
"@firebase/util": "0.3.4",
"@firebase/logger": "0.2.6",
"@firebase/component": "0.1.19",
"@firebase/component": "0.1.21",
"tslib": "^1.11.1",

@@ -43,7 +42,7 @@ "dom-storage": "2.1.0",

"devDependencies": {
"rollup": "2.28.1",
"rollup-plugin-json": "4.0.0",
"rollup": "2.35.1",
"@rollup/plugin-json": "4.1.0",
"rollup-plugin-replace": "2.2.0",
"rollup-plugin-typescript2": "0.27.2",
"typescript": "4.0.2"
"rollup-plugin-typescript2": "0.29.0",
"typescript": "4.0.5"
},

@@ -50,0 +49,0 @@ "repository": {

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

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