Bamazon is an Amazon-like store front that takes in orders from customers and depletes stock from the store's inventory using NodeJS and mySQL!
- Install dependencies
npm i colors console.table inquirer mysql
- Add the following code to a
/config/keys.jsfile:
exports.mysql = {
host: <yourhost>,
port: <yourport>,
user: <yourusername>,
password: <yourpassword>,
database: bamazon_db
};
- Add username to mysql script in
package.jsonfile (change out database name if you choose to do so)
"mysql": "mysql -u <username> -p bamazon_db"
- In terminal, run the following script, and enter password when prompted:
npm run-script mysql
- To run seed schema/data from terminal, copy path to
bamazonSchema.sqlthen run below command. Once Schema has been set up, repeat but forbamazonSeed.sql
source <file path>
- Once set up is complete, run
npm startand begin!
Video Demonstration: https://drive.google.com/file/d/1VR4x-_uIHC8i2AcZZ4-rHiD1vEDr1yTm/view