WebStorm cannot resolve Firebase 9 imports

Viewed 155

My problem is that my IDE (WebStorm) doesn't recognize Firebase imports. It throws the following error:

Cannot resolve symbol getFirestore.

Here are my imports:

import { initializeApp, getApps } from "firebase/app";
import {
    getAuth,
    setPersistence,
    browserSessionPersistence,
} from "firebase/auth";
import { getAnalytics } from "firebase/analytics";
import { getFirestore } from "firebase/firestore";

The code works absolutely fine, but I'd love to have the autocompletion and a file without any errors.

1 Answers

Found the solution, you need to mark node_modules/@firebase in Webstorm to be included... Might be "Mark as not excluded"

Related