Author: Gabriel Ayham Semaan
Supervisor: Samer Murad
Description: MyCatalog is a Value Asset Manager. It allows its users to store valuable assets, like gold or watches, in tables. In addition, MyCatalog boasts a number of features & functionalities that reduce redundant tasks and gives the user a better way to manage their assets. Users can, for example, add an integration that fetches the recent price for gold. Another example would be, a user can receive SMS or Email notifications when the price of their gold drops by 10%.
Development:
npm run start
fires up the react application
npm run server:watch
fires up the nodejs/expressjs server in watch mode
Production:
npm run server
fires up the nodejs/expressjs server and serves the frontend
npm run build
bundles the react app into es5 browser supported vanilla javascript
Adding the remote repository on your local machine
If you don't have a Github account:
- Clone the repository
git clone https://github.com/MisterSemaan/myCatalog.git
- Remove the git file
cd myCatalog && rm -rf .git
If you do have a Github account
- Go to the url
https://github.com/MisterSemaan/myCatalog - Click the 'Fork' button on the top-right corner
Installing dependencies
- Go into the local repository
cd myCatalog
- Client and Server directories have their own package.json files
- Go into client directory and install dependencies
cd client && npm install
- Go into server directory and install dependencies
cd erver && npm install
Connecting to your mongoDB atlas account
- Go to the following url and create a new account
https://www.mongodb.com/ - Follow the instructions of setting up your cluster
- Create a new database and call it
mycatalog
- Go to the connections tab and choose
Connect your application
- Copy the connection string
- Go into your server directory and create a
.env
file
cd server && touch .env
- Create a new key and name it
MOGO_URI
- Paste your connection string as the respective value to the key
MONGO_URI
- Replace the 'password' field with your mongoDB account password
Creating the react env file
- Go into your client directory and create a
env.json
file
cd client && touch env.json
- Paste the following code into your
env.json
file
{
"backendUrl": "http://localhost:5000",
"host": "localhost",
"port": 3000,
"jwtSecret": "",
"apiUserRoute": "/api/user",
"apiAuthRoute": "/api/auth",
"apiCatalogRoute": "/api/catalog",
"newsApiKey": ""
}
For the 'jwtSecret' field, choose any word, phrase combination and paste it into the empty value field. For the 'newsApiKey' do the following:
- Go to the url
https://newsapi.org/ - Click on 'Get API Key'
- Follow the instructions
- Paste the key into the empty value field
Starting the application
- Go into the client directory and run
cd client && npm run start
- Go into the server directory and run
cd server && npm run server