Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 15 additions & 15 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
node_modules/
.expo/
npm-debug.*
*.jks
*.p8
*.p12
*.key
*.mobileprovision
*.orig.*
.env
web-build/

# macOS
.DS_Store

node_modules/
.expo/
npm-debug.*
*.jks
*.p8
*.p12
*.key
*.mobileprovision
*.orig.*
web-build/
# macOS
.DS_Store
config.bat
Binary file removed app/assets/images/bg1.jpg
Binary file not shown.
Binary file removed app/assets/images/bg2.jpg
Binary file not shown.
Binary file removed app/assets/images/bg3.jpg
Binary file not shown.
Binary file removed app/assets/images/splash.png
Binary file not shown.
6 changes: 3 additions & 3 deletions app/components/SearchBar.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React from 'react';
import { View, StyleSheet, Text, TouchableOpacity } from 'react-native';
import { View, StyleSheet, Text, TouchableOpacity, Alert } from 'react-native';
import tailwind from 'tailwind-react-native-classnames';
import { GooglePlacesAutocomplete } from 'react-native-google-places-autocomplete'
import { Ionicons } from '@expo/vector-icons';
Expand All @@ -17,9 +17,9 @@ const SearchBar = ({ setCity, city }) => {
minLength={2}
fetchDetails={true}
returnKeyType={"search"}
onFail={error => console.error(error)}
onFail={error => Alert.alert('Worning', error)}
query={{
key: "GOOGLE_MAP_APIKEY",
key: "",
language: 'en',
}}
styles={{
Expand Down
2 changes: 2 additions & 0 deletions app/navigation/AppNavigator.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ import { loginUser, logoutUser, selectUser } from '../redux/slices/authSlice';
import AuthNavigator from './AuthNavigator';
import { auth } from '../configs/firebase';
import HomeNavigator from './HomeNavigator';
import { LogBox } from 'react-native';
LogBox.ignoreLogs(['new NativeEventEmitter']);

export default function AppNavigator() {
const user = useSelector(selectUser)
Expand Down
9 changes: 5 additions & 4 deletions app/screens/HomeScreen.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import tailwind from 'tailwind-react-native-classnames';
import { localRestaurants } from '../data/localRestaurants';
import colors from '../configs/colors'

const YELP_API_KEY = "YELP_API_KEY";
const YELP_API_KEY = "";

const HomeScreen = () => {
const [restaurantData, setRestaurantData] = useState(localRestaurants)
Expand All @@ -30,17 +30,18 @@ const HomeScreen = () => {
.then((res) => res.json())
.then((json) => {
setLoading(false)
if(json.error) return Alert.alert('Sorry', json.error.description);
if (json.error) return Alert.alert('Sorry', json.error.description);
setRestaurantData(
json?.businesses?.filter((business) =>
business.transactions.includes(activeTab.toLowerCase())
)
)
}
);
})
.catch((err) => console.log(err));
};

useEffect(() => {
return // Remove return after adding Yelp API key
getRestaurantsFromYelp();
}, [city, activeTab]);

Expand Down
30 changes: 15 additions & 15 deletions babel.config.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

43 changes: 22 additions & 21 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,33 +8,34 @@
"eject": "expo eject"
},
"dependencies": {
"@expo/vector-icons": "^12.0.5",
"@react-navigation/bottom-tabs": "^6.0.5",
"@react-navigation/native": "^6.0.2",
"@react-navigation/stack": "^6.0.7",
"@reduxjs/toolkit": "^1.6.1",
"@stripe/stripe-react-native": "0.1.4",
"expo": "^42.0.3",
"expo-google-app-auth": "^8.2.2",
"expo-status-bar": "~1.0.4",
"firebase": "8.2.3",
"@expo/vector-icons": "^13.0.0",
"@react-navigation/bottom-tabs": "^6.3.2",
"@react-navigation/native": "^6.0.11",
"@react-navigation/stack": "^6.2.2",
"@reduxjs/toolkit": "^1.8.3",
"@stripe/stripe-react-native": "0.6.1",
"expo": "^45.0.0",
"expo-google-app-auth": "~8.3.0",
"expo-status-bar": "~1.3.0",
"firebase": "8.8.0",
"formik": "^2.2.9",
"install": "^0.13.0",
"react": "16.13.1",
"react-dom": "16.13.1",
"react-native": "https://github.com/expo/react-native/archive/sdk-42.0.0.tar.gz",
"react-native-bouncy-checkbox": "^2.1.4",
"react-native-dotenv": "^3.2.0",
"react-native-gesture-handler": "~1.10.2",
"react": "17.0.2",
"react-dom": "17.0.2",
"react-native": "0.68.2",
"react-native-bouncy-checkbox": "^3.0.2",
"react-native-dotenv": "^3.3.1",
"react-native-gesture-handler": "~2.2.1",
"react-native-google-places-autocomplete": "^2.4.1",
"react-native-maps": "0.28.0",
"react-native-web": "~0.13.12",
"react-redux": "^7.2.5",
"react-native-maps": "0.30.2",
"react-native-safe-area-context": "4.2.4",
"react-native-web": "0.17.7",
"react-redux": "^8.0.2",
"tailwind-react-native-classnames": "^1.5.1",
"yup": "^0.32.9"
"yup": "^0.32.11"
},
"devDependencies": {
"@babel/core": "^7.9.0"
"@babel/core": "^7.12.9"
},
"private": true
}
Loading