expo-community / expo-firebase-starter Goto Github PK
View Code? Open in Web Editor NEW๐ฅโ๏ธ๐ฑ Expo + Firebase Starter Kit
License: MIT License
๐ฅโ๏ธ๐ฑ Expo + Firebase Starter Kit
License: MIT License
Observing a warning in Xcode Simulator when running your project code:
"React.createElement: type is invalid -- expected a string (for build-in components) or a class/function (for composite components) but got: undefined.
Uploaded screen-shot of Simulator warning: https://ibb.co/J2NYFdq
(available to view for 2 weeks from today, then image file shall be automatically deleted by hosting site).
Did not observe a typo, nor any import mistake; the invoking function call has similar style as used for other screens that do not demonstrate similar warning. As such, this appears to be a single occurrence in the project.
-//-
Furthermore, a minor query:
What is your logic behind not including navigation in this function definition?
your code:
export default function HomeScreen () {
vs
export default function HomeScreen(**{ navigation }**) {
Is this because, as the HomeScreen.js has been implemented, there is no use of navigation within the default function?
Observed this difference when contrasting the implementation of other screens - yet each of these invokes another screen, and therefore has a practical requirement for navigation attribute to be passed into the default function for the screen.
|Thank you |
And how to add a photo and some texts to the database ?
I've been working on implementing my own login flow for a few weeks and have been hunting around for an example of React Native Firebase authentication in which the user is actually verified. Although expo-firebase-starter
is pretty thorough and very well presented, it's a shame that it misses this crucial security aspect.
screen is blank and following issue appeared in console.log after expo start
Uncaught TypeError: (0 , firebase_auth__WEBPACK_IMPORTED_MODULE_1__.getReactNativePersistence) is not a function
at ./config/firebase.js (firebase.js:21:1)
at webpack_require (bootstrap:24:1)
at fn (hot module replacement:62:1)
at ./config/index.js (images.js:3:1)
at webpack_require (bootstrap:24:1)
at fn (hot module replacement:62:1)
at ./components/Button.js (App.js:17:1)
at webpack_require (bootstrap:24:1)
at fn (hot module replacement:62:1)
at ./components/TextInput.js (Logo.js:15:1)
SDK Used: Sdk 46
PLATFORM: Android
After cloning the app using ' npx create-react-native-app --template https://github.com/expo-community/expo-firebase-starter'
I test the app and it works fine on the emulator, but after building the app using EAS, the app seems to crash.
It only shows the loading screen for the app,then it crashes.
After installing the project from expo-firebase-starter, I added eas-cli and expo-development-client to the project. When I build the app through eas and release to testflight the app crashes after showing the loading screen.
I have tested this several times by creating new projects and there is always the same error. It happens only after installing expo-development-client, but when I create new application using expo init and add expo-development-client everything works fine.
Steps to reproduction:
npx create-react-native-app --template https://github.com/expo-community/expo-firebase-starter
npm install -g eas-cli
expo install expo-dev-client
eas build -p ios --profile preview
package.json
{ "main": "node_modules/expo/AppEntry.js", "scripts": { "start": "expo start", "android": "expo start --android", "ios": "expo start --ios", "web": "expo start --web", "eject": "expo eject" }, "dependencies": { "@expo/vector-icons": "^13.0.0", "@react-native-masked-view/masked-view": "0.2.6", "@react-navigation/native": "^6.0.6", "@react-navigation/stack": "^6.0.11", "dotenv": "^10.0.0", "expo": "^45.0.0", "expo-constants": "~13.1.1", "expo-dev-client": "~0.9.6", "firebase": "9.1.0", "formik": "2.1.4", "react": "17.0.2", "react-dom": "17.0.2", "react-native": "^0.68.2", "react-native-gesture-handler": "~2.2.0", "react-native-keyboard-aware-scroll-view": "^0.9.4", "react-native-reanimated": "~2.8.0", "react-native-safe-area-context": "4.2.4", "react-native-screens": "~3.11.1", "react-native-web": "0.17.7", "yup": "0.27.0" }, "devDependencies": { "@babel/core": "^7.12.9", "@babel/runtime": "^7.9.0", "babel-preset-expo": "~9.1.0" }, "private": true, "version": "1.0.0", "name": "my-test-app" }
Hi,
It would be awesome if it was possible to use the template as a typescript project. Manually converting it to typescript doesn't appear to require too many code changes.
Thanks,
Jason
This repository could be set as a template for easier use on new simple projects.
No files were modified from template, this issue occurs when running 'expo start'.
Starting project at /Users/xxx/Projects_A/FireBaseTemplate
Developer tools running on http://localhost:19002
Opening developer tools in the browser...
Starting Metro Bundler
Missing package "metro/src/lib/attachWebsocketServer" in the project at: /Users/xxx/Projects_A/FireBaseTemplate
This usually meansreact-native
is not installed. Please verify that dependencies in package.json include "react-native" and runyarn
ornpm install
.
changing navigation options when passing the component though the context api dosn't work.
Apps.navigationOptions = { title: 'Apps' } export default withFirebaseHOC(Apps)
i see so many warnings.
Warning: Invalid version [email protected] for expo sdkVersion 45.0.0. Use [email protected]
iOS Bundling complete 53599ms
iOS Running app on Tayfun12PM
AsyncStorage has been extracted from react-native core and will be removed in a future release. It can now be installed and imported from '@react-native-async-storage/async-storage' instead of 'react-native'. See https://github.com/react-native-async-storage/async-storage
at node_modules/react-native/Libraries/Utilities/warnOnce.js:27:2 in warnOnce
at node_modules/react-native/index.js:273:12 in module.exports.get__AsyncStorage
at node_modules/@firebase/auth/dist/rn/index.js:127:71 in <global>
at node_modules/metro-runtime/src/polyfills/require.js:339:11 in loadModuleImplementation
at node_modules/firebase/auth/dist/index.esm.js:1:0 in <global>
at node_modules/metro-runtime/src/polyfills/require.js:339:11 in loadModuleImplementation
at navigation/RootNavigator.js:3:0 in <global>
at node_modules/metro-runtime/src/polyfills/require.js:339:11 in loadModuleImplementation
at App.js:4:0 in <global>
at node_modules/metro-runtime/src/polyfills/require.js:339:11 in loadModuleImplementation
at node_modules/expo/AppEntry.js:3:0 in <global>
at node_modules/metro-runtime/src/polyfills/require.js:339:11 in loadModuleImplementation
at node_modules/metro-runtime/src/polyfills/require.js:200:44 in guardedLoadModule
at http://192.168.1.125:19000/node_modules/expo/AppEntry.bundle?platform=ios&dev=true&hot=false&strict=false&minify=false:203844:3 in global code
[react-native-gesture-handler] Seems like you're using an old API with gesture components, check out new Gestures system!
at node_modules/react-native-gesture-handler/src/handlers/createHandler.ts:128:4 in showRngh2NoticeIfNeeded
at node_modules/react-native-gesture-handler/src/handlers/createHandler.ts:176:31 in Handler#constructor
at navigation/RootNavigator.js:21:20 in onAuthStateChanged$argument_1
I found this , installed on my machine. I'm not using AndroidStudio, only Expo CLI/GO and can't have success running the project.
I'm using Windows 7, 32-bits, Node 12.8.3, Expo 4.2.1, Android device 7.1, Expo Go latest (SDK 40.0)
Can you help me? Thanks
Error: Failed to start watch mode.
at Timeout._onTimeout (C:\projects\expo\fb-app\node_modules\jest-haste-map\b
uild\index.js:1059:24)
at listOnTimeout (internal/timers.js:549:17)
at processTimers (internal/timers.js:492:7)
Error: Failed to start watch mode.
at Timeout._onTimeout (C:\projects\expo\fb-app\node_modules\jest-haste-map\b
uild\index.js:1059:24)
at listOnTimeout (internal/timers.js:549:17)
at processTimers (internal/timers.js:492:7)
Error: Failed to start watch mode.
at Timeout._onTimeout (C:\projects\expo\fb-app\node_modules\jest-haste-map\b
uild\index.js:1059:24)
at listOnTimeout (internal/timers.js:549:17)
at processTimers (internal/timers.js:492:7)
Error: Failed to start watch mode.
at Timeout._onTimeout (C:\projects\expo\fb-app\node_modules\jest-haste-map\b
uild\index.js:1059:24)
at listOnTimeout (internal/timers.js:549:17)
at processTimers (internal/timers.js:492:7)
- Stopping server(node:8232) UnhandledPromiseRejectionWarning: Error: Failed to
start watch mode.
at Timeout._onTimeout (C:\projects\expo\fb-app\node_modules\jest-haste-map\b
uild\index.js:1059:24)
at listOnTimeout (internal/timers.js:549:17)
at processTimers (internal/timers.js:492:7)
(node:8232) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This
error originated either by throwing inside of an async function without a catch
block, or by rejecting a promise which was not handled with .catch(). To termina
te the node process on unhandled promise rejection, use the CLI flag `--unhandle
d-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejectio
ns_mode). (rejection id: 2)
(node:8232) [DEP0018] DeprecationWarning: Unhandled promise rejections are depre
cated. In the future, promise rejections that are not handled will terminate the
Node.js process with a non-zero exit code.
โบ Stopped server
C:\projects\expo\fb-app>
Hi,
Its not an issue, i would like to add this as a feature request.
Thanks for the template. Would it be great to enable Social logins like google/facebook/apple etc? as its a common requirement for almost all apps.
Thanks
A great repository collection ,is it possible to extend to google and facebook login as well?
I'm trying to use the user context, but I don't understand the exact working of this one. I want to get the UID of a user with the context but I don't know if it is possible.
Hello,
I created my project using your template (latest release SDK 40), I renamed the firebase config file to firebaseConfig and replaced everything with my own project's information. I didn't change anything else in the code. When I try running the app using android studio and my own phone with the expo app as well, I get stuck on the splash screen. The solutions I found online were either outdated or did not work at all.
@amandeepmittal Thank you for this repo!
I keep it as a reference.
Recently, I landed on this: https://github.com/invertase/react-query-firebase
React Query Firebase provides a set of easy to use hooks for handling asynchronous tasks with Firebase in your React application.
Tested and deployed successfully to production with:
"expo": "^44.0.0",
"firebase": "9.7.0",
Maybe we can update the README.md
in a "Integrating database features" section?
Are you going to propose a rewrite with React Navigation 5?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.