I am creating an Angular 17 SSR project using Angular 17 SSR, Firebase (Angularfire), and VS Code as my IDE.
For reasons I can't explain, there is a generated file somewhere that is throwing errors. I say somewhere because I cannot locate it. When I hover over the filename in the IDE tab, instead of showing me the full path to the file, it just shows the filename.
The generated file (I did not create this file and cannot seem to locate it in any of the node module libraries) has the wrong file paths in it's import statements, which is what is causing the errors. Since I can't find it, it's read-only, and I don't know where it is coming from, I can't fix it, and it is breaking my build.
The file name is 33e09a96-ebe2-4a3b-9423-8ae4672cb096
Here are the contents of the file:
import { doc, onSnapshot } from 'firebase/firestore'; // THESE PATHS ARE WRONG
import { Observable } from 'rxjs'; // e.g. MISSING THE @angular/ PART
function getDocumentObservable(firestore: Firestore, docId: string): Observable<DocumentData> {
const docRef = doc(firestore, 'quizzes', docId);
return new Observable((observer) => {
const unsubscribe = onSnapshot(docRef, {
next: (snapshot) => observer.next(snapshot.data()),
error: (error) => observer.error(error),
complete: () => observer.complete(),
});
// Unsubscribe from the snapshot on observer unsubscribe
return unsubscribe;
});
}
And here is a screenshot: https://app.screencast.com/2VakJPXVf2CZe
Has anyone seen this before? Do you have any ideas on how to fix it?