PhotoLabs is a React-based single-page application (SPA) that allows users to view photos in different contexts. A pre-existing API was used to build a frontend user experience for users to interact with photos!
- The client-side consists of the development of a React single page application (SPA) called PhotoLabs
- The server and persistence layer given as follows:
- The data layer consists of PostgreSQL database
- The API server consists of a Node Express.js server application
- The server/persistence layer may require modifications for stretch goals
- The client will communicate with the API over HTTP using the JSON format
- A user can view photos from the homepage loaded from the API.
- The user can navigate to different photo categories, also called topics.
- The user can click on a photo to view a larger version of the photo and relevant / similar photos.
- The user can like a photo from anywhere within the application where the photo is displayed.
- The user can view a heart icon with a notification in the navigation if there are liked photos.
- The navigation will consist of different topics and heart icon.
- The client-side application will make API requests to load and persist data (i.e. relevant data is not lost after a session restarts, so after a browser refresh).
- UI Feedback: incorporated styling updates to align with all the designer's feedback.
- Reducers with Lookup and constants: to eliminate if conditions and switch/case statements, the reducer was created by using constant values with an object lookup, taking advantage of computed property names.
- Axios: used the Axios library instead of Fetch to retrieve data. Axios is isomorphic (= it can run in the browser and nodejs with the same codebase). On the client-side (browser) it uses XMLHttpRequests.
Install dependencies with npm install
in each respective /frontend
and /backend
.
cd frontend
npm start
Read backend/readme
for further setup details.
cd backend
npm start
For more information regarding creating the database and seeds, plase access the backend README