Commit 28b902e0 authored by Thor-Herman's avatar Thor-Herman
Browse files

Downgrade router version

Caused a whole lot of bugs
parent da7491d9
......@@ -24,11 +24,8 @@ const App = () => {
return (
<Container>
<Header />
<Switch>
<Route exact path='/' component={BrowsePage} />
<Route path='/movie/:movieId' component={MoviePage} />
</Switch>
<Footer />
<Route exact path='/' component={BrowsePage} />
<Route path='/movie/:movieId' component={MoviePage} />
</Container>
);
};
......
......@@ -2,14 +2,13 @@ import { Container, Icon, Input, Item, View } from 'native-base';
import React, { Props, useEffect } from 'react';
import { NativeSyntheticEvent, TextInputChangeEventData, TextInputSubmitEditingEventData } from 'react-native';
import { useDispatch, useSelector } from 'react-redux';
import { Link } from 'react-router-native';
import { useHistory } from 'react-router-native';
import { searchMovieTitles, searchMovies } from '../actions';
import { RootState } from '../reducers';
import history from '../history';
const SearchBar = () => {
const dispatch = useDispatch();
const history = useHistory();
const handleChange = (e: NativeSyntheticEvent<TextInputChangeEventData>): void => {
e.preventDefault();
......
......@@ -3,17 +3,16 @@ import createStore from './store';
import App from './components/App';
import React from 'react';
import { Provider } from 'react-redux';
import history from './history';
import {Router} from 'react-router';
import {NativeRouter} from 'react-router-native';
const store = createStore();
const ReduxApp = () => {
return (
<Provider store={store}>
<Router history={history}>
<NativeRouter>
<App />
</Router>
</NativeRouter>
</Provider>
);
};
......
......@@ -32,7 +32,7 @@
"react-native-web": "~0.13.12",
"react-redux": "^7.2.2",
"react-router": "^5.2.0",
"react-router-native": "^5.2.0",
"react-router-native": "5.1.0",
"redux": "^4.0.5",
"redux-devtools-extension": "^2.13.8",
"redux-thunk": "^2.3.0",
......
......@@ -6153,6 +6153,14 @@ min-document@^2.19.0:
dependencies:
dom-walk "^0.1.0"
mini-create-react-context@^0.3.0:
version "0.3.3"
resolved "https://registry.yarnpkg.com/mini-create-react-context/-/mini-create-react-context-0.3.3.tgz#b1b2bc6604d3a6c5d9752bad7692615410ebb38e"
integrity sha512-TtF6hZE59SGmS4U8529qB+jJFeW6asTLDIpPgvPLSCsooAwJS7QprHIFTqv9/Qh3NdLwQxFYgiHX5lqb6jqzPA==
dependencies:
"@babel/runtime" "^7.12.1"
tiny-warning "^1.0.3"
mini-create-react-context@^0.4.0:
version "0.4.1"
resolved "https://registry.yarnpkg.com/mini-create-react-context/-/mini-create-react-context-0.4.1.tgz#072171561bfdc922da08a60c2197a497cc2d1d5e"
......@@ -7117,15 +7125,31 @@ react-refresh@^0.4.0:
resolved "https://registry.yarnpkg.com/react-refresh/-/react-refresh-0.4.3.tgz#966f1750c191672e76e16c2efa569150cc73ab53"
integrity sha512-Hwln1VNuGl/6bVwnd0Xdn1e84gT/8T9aYNL+HAKDArLCS7LWjwr7StE30IEYbIkx0Vi3vs+coQxe+SQDbGbbpA==
react-router-native@^5.2.0:
version "5.2.0"
resolved "https://registry.yarnpkg.com/react-router-native/-/react-router-native-5.2.0.tgz#40c40856a8d1e3b189c7ad5c1be9b1ead4dbacfd"
integrity sha512-4J9htwyEDpE8mmuZ3vlgsxUd79BU/R64PqMQoXbZU/QM7gaB1O3EEY9MRryidxDmSy+rrTvVe4PjAzGRV0bFFg==
react-router-native@5.1.0:
version "5.1.0"
resolved "https://registry.yarnpkg.com/react-router-native/-/react-router-native-5.1.0.tgz#fc5fd24ddf6d39413731bde3392ee2cd962b49ce"
integrity sha512-dePaODlETaGWDE5izPcTeVej4ueT/69uZPLnq1Yol4BXwlwvjgftVAdS7bpnUlP7XEcbTaQJ1zeFd9VelG8mfg==
dependencies:
prop-types "^15.6.1"
react-router "5.2.0"
react-router "5.1.0"
react-router@5.1.0:
version "5.1.0"
resolved "https://registry.yarnpkg.com/react-router/-/react-router-5.1.0.tgz#739d0f3a57476363374e20d6e33e97f5ce2e00a3"
integrity sha512-n9HXxaL/6yRlig9XPfGyagI8+bUNdqcu7FUAx0/Z+Us22Z8iHsbkyJ21Inebn9HOxI5Nxlfc8GNabkNSeXfhqw==
dependencies:
"@babel/runtime" "^7.1.2"
history "^4.9.0"
hoist-non-react-statics "^3.1.0"
loose-envify "^1.3.1"
mini-create-react-context "^0.3.0"
path-to-regexp "^1.7.0"
prop-types "^15.6.2"
react-is "^16.6.0"
tiny-invariant "^1.0.2"
tiny-warning "^1.0.0"
react-router@5.2.0, react-router@^5.2.0:
react-router@^5.2.0:
version "5.2.0"
resolved "https://registry.yarnpkg.com/react-router/-/react-router-5.2.0.tgz#424e75641ca8747fbf76e5ecca69781aa37ea293"
integrity sha512-smz1DUuFHRKdcJC0jobGo8cVbhO3x50tCL4icacOlcwDOEQPq4TMqwx3sY1TP+DvtTgz4nm3thuo7A+BK2U0Dw==
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment