简体   繁体   English

React-Native-Firebase V6中文件“ firebase.json”的位置

[英]Where the file “firebase.json” goes in React-Native-Firebase V6

The React-Native-Firebase V6 documentation doesn't specify where to create the file, firebase.json . React-Native-Firebase V6文档未指定在何处创建文件firebase.json


"dependencies": {
    "@react-native-firebase/admob": "^0.4.1",
    "@react-native-firebase/app": "^0.1.2",
    "@react-native-firebase/auth": "^0.1.2",
    "@react-native-firebase/firestore": "^0.1.2",
    "matter-js": "^0.14.2",
    "react": "16.8.6",
    "react-native": "0.60.3",
    "react-native-elements": "^1.1.0",
    "react-native-game-engine": "^0.11.5",
    "react-native-gesture-handler": "^1.3.0",
    "react-native-linear-gradient": "^2.5.6",
    "react-native-progress": "^3.6.0",
    "react-native-radial-gradient": "^1.0.5",
    "react-native-share": "^2.0.0",
    "react-native-vector-icons": "^6.6.0",
    "react-navigation": "^3.11.1"
 },

The following errors occur in the console: 控制台中发生以下错误:

  • Where: 哪里:

    • Build file 'D:\\Jesus\\IFEEP AT\\StoreClicker\\StoreSkinClicker\\node_modules@react-native-firebase\\admob\\android\\build.gradle' line: 44 构建文件'D:\\ Jesus \\ IFEEP AT \\ StoreClicker \\ StoreSkinClicker \\ node_modules @ react-native-firebase \\ admob \\ android \\ build.gradle'行:44

  • What went wrong: 什么地方出了错:

    • A problem occurred evaluating project ':@react-native-firebase_admob'. 评估项目':@ react-native-firebase_admob'时发生问题。 No signature of method: java.util.LinkedHashMap.getStringValue() is applicable for argument types: (String, String) values: [admob_app_id, ] 没有方法签名:java.util.LinkedHashMap.getStringValue()适用于参数类型:(字符串,字符串)值:[admob_app_id,]

.JSON文件通常保存在.JSON本机项目的本机文件夹的根目录中,而在android中,我们将其保存在app文件夹中,并尝试提供相对路径。

firebase.json needs to go into the root of your react-native project. firebase.json需要进入您的本机项目的根目录。 Same level as package.json . package.json相同级别。

If you run pod install for ios it will output a line: 如果您为iOS运行pod install,则会输出以下行:

Using firebase.json from '<Path_To_Project>/firebase.json'

I interpret it as the correct position... 我将其解释为正确的位置...

This is how your firebase.json might look like: 这就是您的firebase.json的样子:

 { "react-native": { "ml_vision_face_model": true, "ml_vision_ocr_model": true, "ml_vision_barcode_model": true, "ml_vision_label_model": true, "ml_vision_image_label_model": true } } 

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 iOS 远程通知不起作用 react-native-firebase [v6] - iOS remote notification not working react-native-firebase [v6] 无法从 React-Native-Firebase(v6) Firestore 获取数据:undefined 不是函数(靠近“...this._firestore.native.collectionGet...”) - Can't get data from React-Native-Firebase(v6) Firestore: undefined is not a function (near '...this._firestore.native.collectionGet...') @react-native-firebase 与 react-redux-firebase V3 集成 - @react-native-firebase integration with react-redux-firebase V3 在前台显示通知反应原生 firebase v6 - Show notification on foreground react native firebase v6 react-native-firebase重新发送消息代码 - react-native-firebase resend message code react-native-firebase getInitialNotification循环 - react-native-firebase getInitialNotification loop React-Native-Firebase:RTDB 模拟器 - React-Native-Firebase : RTDB Emulator 云消息传递如何在 react-native-firebase v6.xx 中工作? - How Cloud Messaging Works in react-native-firebase v6.x.x? 哪个 Firebase javascript package 应该与 React Native 一起使用? 常规的“Firebase Web SDK”还是“react-native-firebase”? - Which Firebase javascript package should be used with React Native? The regular "Firebase Web SDK " or "react-native-firebase"? 使用 react-native-firebase 时添加对 Android 通知的回复 - Add replies to Android notifications while using react-native-firebase
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM