Skip to content

Commit a9ee324

Browse files
authored
Merge pull request #194 from padmajabhol/fix-marginals
cleanup code, delete unused files and folders, use useReducer, redo landing page
2 parents e3a1964 + f8bc5b1 commit a9ee324

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

73 files changed

+547
-1552
lines changed

assets/Code is Science - Persona.pdf

-64.4 KB
Binary file not shown.

assets/Contact.webp

-349 KB
Binary file not shown.

assets/Journals.webp

-169 KB
Binary file not shown.

assets/Landing page.webp

-1.78 MB
Binary file not shown.

assets/Manifesto.webp

-675 KB
Binary file not shown.

assets/News articles.webp

-1.23 MB
Binary file not shown.

data/db.json

-228
This file was deleted.

package.json

+1
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@
3030
"react-scripts": "4.0.3",
3131
"react-switch": "^7.0.0",
3232
"react-user-profile": "^1.0.3",
33+
"smooth-scroll": "^16.1.3",
3334
"styled-components": "^5.3.5",
3435
"web-vitals": "^1.0.1"
3536
},

src/App.js

+13-10
Original file line numberDiff line numberDiff line change
@@ -4,23 +4,30 @@
44
/* eslint-disable arrow-body-style */
55
/* eslint-disable max-len */
66
/* eslint-disable no-unused-vars */
7-
import { React, useEffect, useState } from 'react';
7+
import { React } from 'react';
8+
9+
// Libraries
810
import ReactDOM from 'react-dom';
11+
import { BrowserRouter as Router, Switch, Route, Redirect, useHistory } from 'react-router-dom';
912
import { ApolloClient, InMemoryCache, ApolloProvider, HttpLink, from } from '@apollo/client';
13+
import { format } from 'date-fns';
1014
import { onError } from '@apollo/client/link/error';
15+
16+
// Styles
1117
import './index.css';
1218
import 'bootstrap/dist/css/bootstrap.min.css';
13-
import { BrowserRouter as Router, Switch, Route, Redirect, useHistory } from 'react-router-dom';
14-
import { format } from 'date-fns';
19+
20+
// Components
1521
import Profile from './components/Authentication/User-Profile/useprofile';
16-
import { api } from './api/posts';
17-
import { Journal, Contact, Manifesto, Home } from './pages';
22+
import { Journal, Manifesto, Home } from './pages';
1823
import { Footer, Auth, Header, Login, JournalDetails, AddJournal, Layout } from './components';
1924
import Navbar from './components/marginals/Navbar/Navbar';
2025
import Edit from './components/EditJournal/Edit';
21-
import useAxiosFetch from './hooks/useAxiosFetch';
26+
27+
// Context
2228
import { DataProvider } from './context/DataContext';
2329

30+
// React-Apollo setup
2431
const errorLink = onError(({ graphqlErrors, networkError }) => {
2532
if (graphqlErrors) {
2633
graphqlErrors.map(({ message, location, path }) => {
@@ -49,9 +56,6 @@ function App() {
4956
<Route exact path='/'>
5057
<Home />
5158
</Route>
52-
<Route path='/manifesto'>
53-
<Manifesto />
54-
</Route>
5559
<Route path='/journal'>
5660
<Journal />
5761
</Route>
@@ -73,7 +77,6 @@ function App() {
7377
<Route path='/profile'>
7478
<Profile />
7579
</Route>
76-
7780
<Redirect to='/' />
7881
</Switch>
7982
<Footer />

src/api/posts.js

-10
This file was deleted.

src/assets/bg.webp

-1.27 MB
Binary file not shown.

src/assets/clock.webp

-21.2 KB
Binary file not shown.

src/assets/hands-icon.webp

-3.84 KB
Binary file not shown.

src/assets/human-1.webp

-13.4 KB
Binary file not shown.

src/assets/human-2.webp

-7.93 KB
Binary file not shown.

src/assets/logo.webp

-9.11 KB
Binary file not shown.

src/assets/manifesto-img-1.webp

-359 KB
Binary file not shown.

src/assets/peers.webp

-20.6 KB
Binary file not shown.

src/assets/rocket.webp

-8.2 KB
Binary file not shown.

src/assets/section-img.webp

-226 KB
Binary file not shown.

src/assets/talking.webp

-53.2 KB
Binary file not shown.

src/assets/walking-man.webp

-9.2 KB
Binary file not shown.

0 commit comments

Comments
 (0)