Refactor code, split routes, change url in backend and update in frontend. Still have bugs, infinite loading after signup?
This commit is contained in:
11
backend/utils/database.js
Normal file
11
backend/utils/database.js
Normal file
@@ -0,0 +1,11 @@
|
||||
const mysql = require("mysql2");
|
||||
|
||||
//Create a pool of connection to allow multiple query happen at the same time
|
||||
const pool = mysql.createPool({
|
||||
host: "localhost",
|
||||
user: "root",
|
||||
database: "marketplace",
|
||||
password: "12345678",
|
||||
});
|
||||
|
||||
module.exports = pool.promise();
|
||||
Reference in New Issue
Block a user