-
Notifications
You must be signed in to change notification settings - Fork 894
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cannot find namespace 'firebase'.ts(2503)
for with firebase/compat/app
and "moduleResolution": "bundler"
#7279
Comments
I couldn't figure out how to label this issue, so I've labeled it for a human to triage. Hang tight. |
Hi @segevfiner, thanks for the report. I was able to reproduce the behavior. Let me check what we can do for this issue or bring someone here that can provide more context about it. I’ll update this thread if I have any information to share. |
Are you seeing this error when you run |
Ok, the immediate issue is that when you use instead of here (giant index.d.ts file for all compat typings, the expected type source for compat users): Not sure why there's individual compat package typings, I didn't think they worked. Will dig further into it. |
I think it's something we overlooked in #6307 . We should have copied what was in the top level |
We're still going to try to fix this either way but I'm just curious why you're using the compat libraries, is it a legacy application that you're not ready to migrate? |
Yep. It's an application we are going to migrate someday, but it's hard to get time for tech debt where I work at. |
Kindly assign me this issue , if it still exists |
[REQUIRED] Describe your environment
[REQUIRED] Describe the problem
With the new
"moduleResolution": "bundler"
mode of TypeScript 5.0+, TypeScript errors on attempting to access any type from thefirebase
global namespace withfirebase/compat/app
and friends imported. It works with"moduleResolution": "node"
.Steps to reproduce:
pnpm i
pnpm type-check
."moduleResolution": "node"
intsconfig.app.json
it will work, but it should work with the newmoduleResolution
mode as well.Relevant Code:
https://github.com/segevfiner/firebase-types-issue
The text was updated successfully, but these errors were encountered: