Permalink
Cannot retrieve contributors at this time
Name already in use
A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
6012CEM_Movie_Club/flask-react/src/App.js
Go to fileThis commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
42 lines (38 sloc)
1.81 KB
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, {useEffect,useState} from 'react'; | |
import './App.css'; | |
import HomePage from './components/HomePage.js'; | |
import AllMovies from "./components/AllMovies.js"; | |
//import Recommended from './components/Recommended.js'; | |
import MyReviews from './components/MyReviews.js'; | |
import { Container } from "semantic-ui-react"; | |
import { Route, BrowserRouter, Switch } from 'react-router-dom' | |
import NavBar from './components/NavBar.js'; | |
import Login from './components/Login.js'; | |
import Register from './components/Register.js'; | |
import AddReview from './components/AddReview.js'; | |
import MovieCoverPage from './components/MoviePage.js'; | |
import Categories from './components/Categories.js'; | |
import Account from './components/Account.js'; | |
import Recommended from './components/Recommended.js'; | |
import SearchResults from './components/SearchResults.js'; | |
function App() { | |
return ( | |
<BrowserRouter> | |
<NavBar/> | |
<Switch> | |
<Route exact path='/' component={ HomePage } /> | |
<Route exact path='/allmovies' component={ AllMovies } /> | |
<Route exact path='/myreviews' component={ MyReviews } /> | |
<Route exact path="/login" component={ Login } /> | |
<Route exact path="/register" component={ Register } /> | |
<Route exact path="/recommended" component={ Recommended } /> | |
<Route exact path="/account/:id" component={ Account } /> | |
<Route exact path="/addreview/:id" component={ AddReview } /> | |
<Route exact path="/search/:searchTerm" component={ SearchResults } /> | |
<Route exact path="/categories/:category" component={ Categories } /> | |
<Route exact path="/movies/:id" component={ MovieCoverPage } /> | |
</Switch> | |
</BrowserRouter> | |
); | |
} | |
export default App; |