No Description
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

index.esm.js 2.6KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  1. import firebase from '@firebase/app-compat';
  2. import { Component } from '@firebase/component';
  3. import { getId, getToken, deleteInstallations, onIdChange } from '@firebase/installations';
  4. var name = "@firebase/installations-compat";
  5. var version = "0.2.1";
  6. /**
  7. * @license
  8. * Copyright 2020 Google LLC
  9. *
  10. * Licensed under the Apache License, Version 2.0 (the "License");
  11. * you may not use this file except in compliance with the License.
  12. * You may obtain a copy of the License at
  13. *
  14. * http://www.apache.org/licenses/LICENSE-2.0
  15. *
  16. * Unless required by applicable law or agreed to in writing, software
  17. * distributed under the License is distributed on an "AS IS" BASIS,
  18. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  19. * See the License for the specific language governing permissions and
  20. * limitations under the License.
  21. */
  22. var InstallationsCompat = /** @class */ (function () {
  23. function InstallationsCompat(app, _delegate) {
  24. this.app = app;
  25. this._delegate = _delegate;
  26. }
  27. InstallationsCompat.prototype.getId = function () {
  28. return getId(this._delegate);
  29. };
  30. InstallationsCompat.prototype.getToken = function (forceRefresh) {
  31. return getToken(this._delegate, forceRefresh);
  32. };
  33. InstallationsCompat.prototype.delete = function () {
  34. return deleteInstallations(this._delegate);
  35. };
  36. InstallationsCompat.prototype.onIdChange = function (callback) {
  37. return onIdChange(this._delegate, callback);
  38. };
  39. return InstallationsCompat;
  40. }());
  41. /**
  42. * @license
  43. * Copyright 2020 Google LLC
  44. *
  45. * Licensed under the Apache License, Version 2.0 (the "License");
  46. * you may not use this file except in compliance with the License.
  47. * You may obtain a copy of the License at
  48. *
  49. * http://www.apache.org/licenses/LICENSE-2.0
  50. *
  51. * Unless required by applicable law or agreed to in writing, software
  52. * distributed under the License is distributed on an "AS IS" BASIS,
  53. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  54. * See the License for the specific language governing permissions and
  55. * limitations under the License.
  56. */
  57. function registerInstallations(instance) {
  58. instance.INTERNAL.registerComponent(new Component('installations-compat', function (container) {
  59. var app = container.getProvider('app-compat').getImmediate();
  60. var installations = container
  61. .getProvider('installations')
  62. .getImmediate();
  63. return new InstallationsCompat(app, installations);
  64. }, "PUBLIC" /* ComponentType.PUBLIC */));
  65. instance.registerVersion(name, version);
  66. }
  67. registerInstallations(firebase);
  68. //# sourceMappingURL=index.esm.js.map