An app to browse dogs available for adoption using an instagram-like frontend UI along with the petfinder API for the backend.
-
Follow this MongoDB Atlas Tutorial
-
Add your mongoURI to
config/default.json
- How to get petfinder API and SECRET KEY? Follow this link
npm install
Install backend dependencies for the app.
npm clientinstall
Install client (frontend) dependencies for the app.
npm run start
Starts the server, however any changes made requires to manually restart the server to see changes.
npm run server
Start the server and any detected changes made will automatically restart the server.
npm run dev
Run both the server and frontend client.
Due to react-router-dom
being updated to v6, for <Route>
, component
was replaced with element
. In order to be able to use Context.Provider
, the global state, I need to set element={<someComponent/>}
and NOT AS element={someComponent()}
otherwise useContext()
will always return undefined for someComponent
.