Firebase Admin
Firebase analytics
Pricing
Privacy and Security
Useful resources
Firebase Extensions
Cloud Run
Typescript typings
If you start using Firebase in your Typescript application you need to let Typescript know about this global firebase variable that you know have access to. First install firebase not to import but simply to get access to the types contained within:
1
npm i -D firebase
Copied!
Now create a src/firebase.d.ts file and copy the following:
1
import firebase from 'firebase'
2
​
3
declare global {
4
export const firebase = firebase
5
}
Copied!
Now you have full typescripts bindings available.
Copy link