-
Notifications
You must be signed in to change notification settings - Fork 916
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
typescript minimum version not indicated by peer dependency #8837
Comments
I couldn't figure out how to label this issue, so I've labeled it for a human to triage. Hang tight. |
Hi @brantgurga, thanks for the report! I was able to reproduce the behavior on my end. I’ll investigate further to see what we can do to resolve this or loop in someone who can provide more context. I’ll keep this thread updated as soon as I have more details. |
Hi @brantgurga, thanks for reporting this issue! Since this SDK is designed for use by both TS and JS users, we can't add a peer dependency for TS. We are looking into alternatives that will allow us to support JS, while enforcing a minimum TS version- we'll keep you updated! |
@dlarocque I was wondering about that. I think peer dependency is the right way in the dependency model, but npm has changed its peer dependency handling at times, sometimes auto-installing peer dependencies and other times just warning that they aren't there or are unsatisfied. Looks like peerDependency to give the appropriate minimum typescript version would do it along with a peerDependencyMeta that marks typescript as optional so it doesn't automatically install. Or at least so conveys the current package.json documentation. |
Operating System
Linux
Environment (if applicable)
Typescript
Firebase SDK Version
11.4.0
Firebase SDK Product(s)
Installations
Project Tooling
React app via React-scripts (Create React App)
Detailed Problem Description
Updated to latest firebase dependency and the typescript compile failed for firebase having type modifiers on import names. So the current version requires typescript to be at least 4.5 to support that, but it's not indicated by the package.json dependencies.
Steps and code to reproduce issue
Use typescript before 4.5 and see a typescript compile fail on the syntaxes like import {type MyType} from 'firebase'
The text was updated successfully, but these errors were encountered: