我正在学习一个教程,我不知道问题是什么?当我尝试import { db } from '../firebase.config'时,我一直收到一个错误。
我已经尝试了所有的东西,并且查看了git中的教程代码,它们是相同的,所以我认为这个问题是新的。
这是firebase.config.js文件和SignUp.jsx文件,我试图导入db。
// Import the functions you need from the SDKs you need
import { initializeApp } from "firebase/app";
i
const firebaseConfig = {
// I have config living here
}
const firebaseConfigDev = {
// I have dev config
}
let config
if (process.env.NODE_ENV === 'production') {
config = firebaseConfig
} else {
config = firebaseConfigDev
}
if (!firebase.apps.length) {
firebase.initia
我正在尝试在我的react.js项目中实现firebase。为了遵循说明,我目前正在使用firebase版本7.15.5 (至少我认为,因为我的两个.json文件都使用了firebase 7.15.5),所以我的语法与指令相同。当我进入npm start我的react项目时,我会得到以下错误:
Failed to compile.
Module not found: Error: Package path . is not exported from package /Users/jasonvitalejr/react-app/grey-hackbu/node_modules/firebas
Uncaught TypeError: _firebase__WEBPACK_IMPORTED_MODULE_1__.default.auth.RecaptchaVerifier is not a constructor
这就是当我试图在我的react应用程序中实现otp验证时所遇到的错误。
代码
import React, { Component } from 'react'
import db from '../firebase'
export class LooginOTP extends Component {
handleClick=()=>
我正在尝试使用以下命令将我的React Native Project导出为APK文件: ./gradlew汇编 并接收到以下错误: 任务:应用程序:bundleDebugJsAndAssets失败 以下是我在执行时的警告输出。是否存在可能会折旧的依赖项?我似乎不能确定为什么我不能构建我需要的APK文件。 我不确定我是否需要为firebase兼容性降级我的gradle。 Configure project :app
useNewCruncher has been deprecated. It will be removed in a future version of the gradle p
遇到了一个很奇怪的问题。当试图导入firebase时,我得到了以下错误:
./node_modules/firebaseui/dist/esm.js
Attempted import error: 'app' is not exported from 'firebase/app' (imported as 'firebase').
我的项目的结构是:包含react客户端文件夹的父文件夹。我在父文件夹中安装了firebase,在父文件夹中的firebaseConfig文件中初始化了一个firebase应用程序,然后将它导入到react文件夹中。
后
我试图在我的网站中建立身份验证,但我遇到了一个我在其他地方没有见过的问题,所以我决定在这里问它。Web浏览器返回此错误:_firebase_js__WEBPACK_IMPORTED_MODULE_1__.firebase.auth.GoogleAuthProvider is not a constructor。 我的firebase.js文件如下所示: import fb from 'firebase/app';
require('firebase/firestore');
require('firebase/auth');
export co
我使用作为入门模板,使用firebase构建react原生应用程序。
我正在使用Home.js中的以下文件,并希望将数据保存到firebase,但遇到错误。错误。
firebase.database is not a function. (In 'firebase.database(reflection)', 'firebase.database' is undefined)
这是我正在使用的代码。当有人编写反射时,我会尝试将该反射文本与用户ID一起保存。
import React, {useEffect, useState } from "react&
尝试在我的react应用程序中使用firebase来实现用户身份验证。我有一个firebase.js文件,其中定义了寄存器/登录/注销函数,然后将其导入登录/注册屏幕。我没有任何错误,直到我真正尝试注册一个用户,然后我得到错误的标题。
import { useState } from 'react';
import { Link } from "react-router-dom";
import register from "../firebase";
import "../css/RegisterScreen.css";
fu
我正在尝试将firebase连接到我的世博应用程序,但它似乎无法读取我的firebase类中的函数。有什么想法吗?
import Fire from "./Fire";
export default class App extends React.Component {
componentDidMount() {
var firebase = new Fire((error, user) => {
if (error) {
return alert("uh, oh, something we
我一直在试图解决我的问题,但我什么也没做。当我试图编译我的react应用程序时,我收到了以下消息:
./src/context_state_config.js
Attempted import error: 'PostsReducer' is not exported from './store/reducers/posts_reducer'
这是我的还原机文件:
import * as ACTION_TYPES from '../actions/action_types'
const initialState = {
post: [],