sveltefire
sveltefire copied to clipboard
Firebase analytics are initialized even when they're unsupported
Firebase analytics are initialized when they're unsupported resulting in the following error:
Uncaught (in promise) FirebaseError: Analytics: Environment doesn't support IndexedDB: A mutation operation was attempted on a database that did not allow mutations.. Wrap initialization of analytics in analytics.isSupported() to prevent initialization in unsupported environments (analytics/invalid-indexedDB-context).
It is recommended that remote config should not be initialized when it unsupported (https://github.com/firebase/firebase-js-sdk/issues/2373#issuecomment-557293448). The library should handle that.