Created
January 3, 2023 01:07
-
-
Save maxencehenneron/bb0be0b04a6571cbc4a21a3b33e23a58 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { firebase } from '@react-native-firebase/analytics'; | |
export default { | |
logEvent: ( | |
name: string, | |
params?: { [key: string]: any }, | |
): Promise<void> => firebase.analytics().logEvent(name, params), | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { getAnalytics, logEvent } from 'firebase/analytics'; | |
import { initializeApp } from 'firebase/app'; | |
import firebaseConfig from '../../constants/firebase-web'; | |
const firebase = initializeApp(firebaseConfig); | |
const analytics = getAnalytics(firebase); | |
export default { | |
logEvent: ( | |
name: string, | |
params?: { [key: string]: any }, | |
) => { | |
logEvent(analytics, name, params); | |
}, | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment