Coder Social home page Coder Social logo

react-native-airbnb-clone's Introduction

react-native-airbnb-clone

AirBnB mobile app clone using React Native & Redux

How to use

  • Clone
  • Run npm install in the terminal
  • Run on IOS or Android projects in emulator

Login details

Dependencies

  • react
  • react-native
  • react-native-vector-icons
  • react-navigation
  • react-redux
  • redux
  • redux-logger
  • redux-thunk

react-native-airbnb-clone's People

Contributors

imandyie avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

react-native-airbnb-clone's Issues

error: bundling failed: Error: While resolving module `react-native-vector-icons/FontAwesome`

If you're getting the following error:

error: bundling failed: Error: While resolving module react-native-vector-icons/FontAwesome, the Haste package react-native-vector-icons was found. However the module FontAwesome could not be found within the package. Indeed, none of these files exist:

the following command should fix it:
rm ./node_modules/react-native/local-cli/core/__fixtures__/files/package.json

Source: oblador/react-native-vector-icons#626

ld: library not found for -lRCTGeolocation clang: error: linker command failed with exit code 1 (use -v to see invocation)

Detailed issue when I build and run it in the xcode:


Ld /Users/user1/Library/Developer/Xcode/DerivedData/AirbnbClone-gmhlnxspkueduzgxqsxyhvifrkxa/Build/Products/Debug-iphoneos/AirbnbClone.app/AirbnbClone normal arm64 (in target: AirbnbClone)
cd /Users/user1/Desktop/airbnb-clone/ios
export IPHONEOS_DEPLOYMENT_TARGET=8.0
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -arch arm64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS12.2.sdk -L/Users/user1/Library/Developer/Xcode/DerivedData/AirbnbClone-gmhlnxspkueduzgxqsxyhvifrkxa/Build/Products/Debug-iphoneos -F/Users/user1/Library/Developer/Xcode/DerivedData/AirbnbClone-gmhlnxspkueduzgxqsxyhvifrkxa/Build/Products/Debug-iphoneos -filelist /Users/user1/Library/Developer/Xcode/DerivedData/AirbnbClone-gmhlnxspkueduzgxqsxyhvifrkxa/Build/Intermediates.noindex/AirbnbClone.build/Debug-iphoneos/AirbnbClone.build/Objects-normal/arm64/AirbnbClone.LinkFileList -Xlinker -rpath -Xlinker @executable_path/Frameworks -miphoneos-version-min=8.0 -Xlinker -object_path_lto -Xlinker /Users/user1/Library/Developer/Xcode/DerivedData/AirbnbClone-gmhlnxspkueduzgxqsxyhvifrkxa/Build/Intermediates.noindex/AirbnbClone.build/Debug-iphoneos/AirbnbClone.build/Objects-normal/arm64/AirbnbClone_lto.o -Xlinker -no_deduplicate -fembed-bitcode-marker -fobjc-arc -fobjc-link-runtime -ObjC -lc++ /Users/user1/Library/Developer/Xcode/DerivedData/AirbnbClone-gmhlnxspkueduzgxqsxyhvifrkxa/Build/Products/Debug-iphoneos/libRCTBlob.a /Users/user1/Library/Developer/Xcode/DerivedData/AirbnbClone-gmhlnxspkueduzgxqsxyhvifrkxa/Build/Products/Debug-iphoneos/libRCTAnimation.a /Users/user1/Library/Developer/Xcode/DerivedData/AirbnbClone-gmhlnxspkueduzgxqsxyhvifrkxa/Build/Products/Debug-iphoneos/libReact.a /Users/user1/Library/Developer/Xcode/DerivedData/AirbnbClone-gmhlnxspkueduzgxqsxyhvifrkxa/Build/Products/Debug-iphoneos/libRCTAnimation.a /Users/user1/Library/Developer/Xcode/DerivedData/AirbnbClone-gmhlnxspkueduzgxqsxyhvifrkxa/Build/Products/Debug-iphoneos/libRCTActionSheet.a -lRCTGeolocation /Users/user1/Library/Developer/Xcode/DerivedData/AirbnbClone-gmhlnxspkueduzgxqsxyhvifrkxa/Build/Products/Debug-iphoneos/libRCTImage.a /Users/user1/Library/Developer/Xcode/DerivedData/AirbnbClone-gmhlnxspkueduzgxqsxyhvifrkxa/Build/Products/Debug-iphoneos/libRCTLinking.a /Users/user1/Library/Developer/Xcode/DerivedData/AirbnbClone-gmhlnxspkueduzgxqsxyhvifrkxa/Build/Products/Debug-iphoneos/libRCTNetwork.a /Users/user1/Library/Developer/Xcode/DerivedData/AirbnbClone-gmhlnxspkueduzgxqsxyhvifrkxa/Build/Products/Debug-iphoneos/libRCTSettings.a /Users/user1/Library/Developer/Xcode/DerivedData/AirbnbClone-gmhlnxspkueduzgxqsxyhvifrkxa/Build/Products/Debug-iphoneos/libRCTText.a /Users/user1/Library/Developer/Xcode/DerivedData/AirbnbClone-gmhlnxspkueduzgxqsxyhvifrkxa/Build/Products/Debug-iphoneos/libRCTVibration.a /Users/user1/Library/Developer/Xcode/DerivedData/AirbnbClone-gmhlnxspkueduzgxqsxyhvifrkxa/Build/Products/Debug-iphoneos/libRCTWebSocket.a -lRNVectorIcons -Xlinker -dependency_info -Xlinker /Users/user1/Library/Developer/Xcode/DerivedData/AirbnbClone-gmhlnxspkueduzgxqsxyhvifrkxa/Build/Intermediates.noindex/AirbnbClone.build/Debug-iphoneos/AirbnbClone.build/Objects-normal/arm64/AirbnbClone_dependency_info.dat -o /Users/user1/Library/Developer/Xcode/DerivedData/AirbnbClone-gmhlnxspkueduzgxqsxyhvifrkxa/Build/Products/Debug-iphoneos/AirbnbClone.app/AirbnbClone

react error

what command did you use to build the app?
was react init or create?

I have error when compile application for android(windows)

I have a error:

image

package.json:
{
"name": "AirbnbClone",
"version": "0.0.1",
"private": true,
"scripts": {
"start": "node node_modules/react-native/local-cli/cli.js start",
"test": "jest",
"lint": "./node_modules/.bin/eslint src/"
},
"dependencies": {
"apollo-cache-inmemory": "^1.2.8",
"apollo-client": "^2.4.0",
"apollo-link-http": "^1.5.4",
"graphql": "^0.13.2",
"graphql-tag": "^2.9.2",
"prop-types": "^15.6.2",
"react": "^16.4.1",
"react-apollo": "^2.1.11",
"react-native": "^0.56.0",
"react-native-vector-icons": "^4.6.0",
"react-navigation": "^2.6.2",
"react-navigation-redux-helpers": "^2.0.2",
"react-redux": "^5.0.7",
"redux": "^4.0.0",
"redux-logger": "^3.0.6",
"redux-thunk": "^2.3.0"
},
"devDependencies": {
"babel-eslint": "^8.2.5",
"babel-jest": "22.4.3",
"babel-preset-react-native": "5.0.0",
"eslint": "^4.19.1",
"eslint-config-airbnb": "^17.0.0",
"eslint-plugin-import": "^2.13.0",
"eslint-plugin-jsx-a11y": "^6.1.0",
"eslint-plugin-react": "^7.10.0",
"jest": "22.4.3",
"react-test-renderer": "16.3.1"
},
"jest": {
"preset": "react-native"
}
}

Navigation reducer error

Hi somehow i am unable to run project with nav reducer from your code.
In order to make it work i had to create reducer inside AppNavigator like this:

const navReducer = createNavigationReducer(RootNavigator);
const reducer = combineReducers({
    nav: navReducer,
});

and change configureStore (in my case just store) to this:

const store = createStore(
    reducer,
    applyMiddleware(middleware, thunkMiddleware, loggerMiddleware),
);

App is still working the same I think after this changes...but i cant change the status bar now like u did

Here is the full code of AppNavigator.js

import {
    createStore,
    applyMiddleware,
    combineReducers,
} from 'redux';
import {
    reduxifyNavigator,
    createReactNavigationReduxMiddleware,
    createNavigationReducer,
} from 'react-navigation-redux-helpers';
import { createLogger } from 'redux-logger';
import thunkMiddleware from 'redux-thunk';
import { connect } from 'react-redux';
import React from 'react';
import RootNavigator from './RootNavigator'

const navReducer = createNavigationReducer(RootNavigator);
const reducer = combineReducers({
    nav: navReducer,
});


// Note: createReactNavigationReduxMiddleware must be run before reduxifyNavigator
const middleware = createReactNavigationReduxMiddleware(
    "root",
    state => state.nav,
);

const App = reduxifyNavigator(RootNavigator, "root");
const mapStateToProps = (state) => ({
    state: state.nav,
});

const AppWithNavigationState = connect(mapStateToProps)(App);

const loggerMiddleware = createLogger({ predicate: () => __DEV__ });

const store = createStore(
    reducer,
    applyMiddleware(middleware, thunkMiddleware, loggerMiddleware),
);

const Root = () => <AppWithNavigationState />;

export {
    store,
    Root,
};

I am using react-navigation v3

this.setState => protected member is not accessible...

Don't working this code.

export default class LogIn extends Component {
  constructor(props) {
    super(props);
    this.state = {
      formValid: false,
    };
    this.handleCloseNotification = this.handleCloseNotification.bind(this);
  }

  handleCloseNotification() {
    this.setState({ formValid: true });
  }

I am getting this error on Webstorm.
this.setState => protected member is not accessible...

help me.

Want to be updated react-native version

I am working on a project that will use react-native 6.0 or above as it provides auto-linking.

Can you make another branch with updated react-native version

As it comes with a lot of changes.

Also, I am not familiar with redux.

Choose a License

You have a really great job here, I'm sure this is helping people around.

To make sure we can reuse the code here, please put on the repo a license that assures the programmers the freedom of code using. I, personally, recommend the MIT license.

error: bundling failed: Error: Unable to resolve module `AccessibilityInfo`

error: bundling failed: Error: Unable to resolve module AccessibilityInfo from E:\xampp_new\htdocs\react-native-airbnb-clone\node_modules\react-native\Libraries\react-native\react-native-implementation.js: Module AccessibilityInfo does not exist in the Haste module map

This might be related to facebook/react-native#4968
To resolve try the following:

  1. Clear watchman watches: watchman watch-del-all.
  2. Delete the node_modules folder: rm -rf node_modules && npm install.
  3. Reset Metro Bundler cache: rm -rf /tmp/metro-bundler-cache-* or npm start -- --reset-cache. 4. Remove haste cache: rm -rf /tmp/haste-map-react-native-packager-*.
    at ModuleResolver.resolveDependency (E:\xampp_new\htdocs\react-native-airbnb-clone\node_modules\metro\src\node-haste\DependencyGraph\ModuleResolution.js:167:1306)
    at ResolutionRequest.resolveDependency (E:\xampp_new\htdocs\react-native-airbnb-clone\node_modules\metro\src\node-haste\DependencyGraph\ResolutionRequest.js:80:16)
    at DependencyGraph.resolveDependency (E:\xampp_new\htdocs\react-native-airbnb-clone\node_modules\metro\src\node-haste\DependencyGraph.js:237:485)
    at Object.resolve (E:\xampp_new\htdocs\react-native-airbnb-clone\node_modules\metro\src\lib\transformHelpers.js:116:25)
    at dependencies.map.result (E:\xampp_new\htdocs\react-native-airbnb-clone\node_modules\metro\src\DeltaBundler\traverseDependencies.js:298:29)
    at Array.map ()
    at resolveDependencies (E:\xampp_new\htdocs\react-native-airbnb-clone\node_modules\metro\src\DeltaBundler\traverseDependencies.js:294:16)
    at E:\xampp_new\htdocs\react-native-airbnb-clone\node_modules\metro\src\DeltaBundler\traverseDependencies.js:159:33
    at Generator.next ()
    at step (E:\xampp_new\htdocs\react-native-airbnb-clone\node_modules\metro\src\DeltaBundler\traverseDependencies.js:239:307)
    BUNDLE [android, dev] ./index.js ââââââââââââââââ 0.0% (1/52), failed.

Request to add Licence

Hello,

I am Maheshwari from GeekyAnts. We have open source website "Start-React" where we add open source products which we find helpful to the community & also we provide credits to author itself.
Let me know if you are interested to showcase your product in our open source website. If yes, then I request you to add MIT or Apache Licence in your repo.
Looking forward to hear from you.

cannot use import statement outside a module

I run react-native run-android in cmd, after changing path to the project folder, but it shows the following error:

import type {CommandT} from './commands';
^^^^^^

SyntaxError: Cannot use import statement outside a module
at wrapSafe (internal/modules/cjs/loader.js:1117:16)
at Module._compile (internal/modules/cjs/loader.js:1165:27)
at Module._compile (C:\Users\saran\react-native-airbnb-clone\node_modules\pirates\lib\index.js:91:24)
at Module._extensions..js (internal/modules/cjs/loader.js:1221:10)
at Object.newLoader [as .js] (C:\Users\saran\react-native-airbnb-clone\node_modules\pirates\lib\index.js:96:7)
at Module.load (internal/modules/cjs/loader.js:1050:32)
at Function.Module._load (internal/modules/cjs/loader.js:938:14)
at Module.require (internal/modules/cjs/loader.js:1090:19)
at require (internal/modules/cjs/helpers.js:75:18)
at Object. (C:\Users\saran\react-native-airbnb-clone\node_modules\react-native\local-cli\cli.js:21:16)

Error Invariant Violation

Invariant Violation: Element type is invalid: expected a string (for built-in components) or a class/function (for composite components) but got: object. You likely forgot to export your component from the file it's defined in

Error credentials

the given credentials are not working for my app. not sure if capitalization plays a role

launching on Android Emulator Error

Once project is clonned with dependencies installed, I ran react-native run-android

My emulator is launched by AVD Manager from Android Studio. Other apps runs pretty well.

I got the next error
Capture

Thanks

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.