Since updating to firebase 9, I've been encountering issues with importing certain functions that were working fine on firebase 8. I've gone through the documentation and made necessary code improvements, but the error persists. This issue is not limited to just one import.
The imports in question are:
import { initializeApp } from 'firebase/app'
import { getDatabase } from 'firebase/database'
import { getAuth, signInWithCustomToken, onAuthStateChanged } from 'firebase/auth'
The specific error message reads:
Export 'initializeApp' was not found in 'firebase/app'
I also attempted using the compat libraries:
import { initializeApp } from 'firebase/compat/app'
import { getDatabase } from 'firebase/compat/database'
import { getAuth, signInWithCustomToken, onAuthStateChanged } from 'firebase/compat/auth'
However, the warning persisted, stating:
WARNING "export 'initializeApp' was not found in 'firebase/compat/app'
This issue extends to other imports as well. Any suggestions or assistance would be greatly appreciated.