Home>
I get an error like the second photo in the application development using reactnative. The file structure is like the first piece of the photo.
Also, the main is app.js and the code is below.
import * as firebase from'firebase';
import {createAppContainer} from'react-navigation';
import {createStackNavigator} from'react-navigation-stack';
import MemoListScreen from'./src/screens/MemoListScreen';
import MemoDetailScreen from'./src/screens/MemoDetailScreen';
import MemoEditScreen from'./src/screens/MemoEditScreen';
import LoginScreen from'./src/screens/LoginScreen';
import SignupScreen from'./src/screens/SignupScreen';
/* eslint-disable */
const firebaseConfig = {
apiKey: "**************************************:",
authDomain: "**********************************",
databaseURL: "**************************************",
projectId: "**********************************",
storageBucket: "**********************************",
messagingSenderId: "**********************************",
appId: "**************************************",
measurementId: "********************"
};
firebase.default.initializeApp(firebaseConfig);
firebase.analytics();
// So far
const AppNavigator = createStackNavigator({
Login: {screen: LoginScreen },
Signup: {screen: SignupScreen },
Home: {screen: MemoListScreen },
MemoDetail: {screen: MemoDetailScreen },
MemoDetail: {screen: MemoDetailScreen },
MemoEdit: {screen: MemoEditScreen },
}, {
defaultNavigationOptions: {
headerTitle:'memo',
headerTintColor:'#fff',
headerBackTitle: null,
headerStyle: {
backgroundColor:'#265366',
},
headerTitleStyle: {
color:'#fff',
},
},
});
export default createAppContainer(App);
The installation of firebase has stopped working, so there is probably a problem there.
What I did was register firebase and run the command npm install --save [email protected]
If anyone knows the cause of the error, please teach me.
-
Answer # 1
Related articles
- [react native] i want to jump to the error part when an error occurs in the form
- reactjs - react + firestore an error occurs when trying to call multiple collections
- react native - [hook error] notification of react and expo is set in state
- error building react native development environment
- ruby - an error occurs in yamldump using rspec string io
- java - kod-i want to know what to do when an error occurs in a method that should not have been written
- python - list index out of range error occurs for index 0
- android studio - null-related error, the application crashes and cannot be resolved
- python - time-out error occurs during communication
- small error occurs in calculation using% of python
- an error occurs when installing the postgresql12 develop file on aws (ec2)
- python - error occurs only in debug mode in vba
- machine learning - unicodedecodeerror error occurs when creating original model of keras-yolo3
- php - i want to solve the problem that an error occurs as soon as i put $result = $stmt-> fetch (pdo :: fetch_assoc) ;
- unity - gui error: an error occurs when creating a folder or script
- react typescript type error when updating state
- a 400 error occurs when sending post from php to gas (google spread sheet) with curl
- python 3x - an error occurs in the library for python3 tkinter drag and drop
- firebase - i want to rewrite [react native] class component to finction component
Trends
- php - coincheck api authentication doesn't work
- php - i would like to introduce the coincheck api so that i can make payments with bitcoin on my ec site
- [php] i want to get account information using coincheck api
- python - you may need to restart the kernel to use updated packages error
- the emulator process for avd pixel_2_api_29 was killed occurred when the android studio emulator was started, so i would like to
- python 3x - typeerror: 'method' object is not subscriptable
- javascript - how to check if an element exists in puppeteer
- xcode - pod install [!] no `podfile 'found in the project directory
- i want to call a child component method from a parent in vuejs
- vuejs - [vuetify] unable to locate target [data-app] i want to unit test to avoid warning
I wonder if it may not have been installed in the first place?
Check if you have firebase in package.json
If not,
Move to the target PJ with the terminal cd command, and then
Please try installing firebase again by referring to the following
https://qiita.com/yonabe710/items/1f4e4e242698d7b897fc
https://qiita.com/Alex_mht_code/items/e5cd95b8f2a2a3ce656f
npm install -g firebase-tools