【发布时间】:2018-11-18 15:35:48
【问题描述】:
每当我尝试使用 firebase auth 部分运行我的应用程序时,我的 Android 模拟器上都会出现此错误。当我删除它很好。这可能是什么问题?
Objects are not valid as a React child (found: object with keys {typeof, type, key, ref, props, _owner, _store}). If you meant to render a collection of children, use an array instead.
throwOnInvalidObjectType
ReactNativeRenderer-dev.js:9616:6
reconcileChildFibers
这是我的代码
import React, { Component } from 'react';
import { View } from 'react-native';
import firebase from 'firebase'
import { Header } from './components/common';
import LoginForm from './components/LoginForm';
class App extends Component {
componentWilMount() {
firebase.initializeApp({
apiKey: 'AIzaSyB1eIxhsVkgc9FEv2iwAmbOWVL3ksKBENc',
authDomain: 'authentication-47519.firebaseapp.com',
databaseURL: 'https://authentication-47519.firebaseio.com',
projectId: 'authentication-47519',
storageBucket: 'authentication-47519.appspot.com',
messagingSenderId: '823214787474'
});
}
render() {
return (
<View>
<Header headerText="Authentication" />
<LoginForm />
</View>
);
}
}
export default App;
这可能是什么错误??
【问题讨论】:
-
您使用哪种身份验证?谷歌或电子邮件和密码?并且它只对模拟器失败
-
邮箱密码,在真机和模拟器上都不起作用
标签: javascript android firebase react-native firebase-authentication