|
|
@ -3,6 +3,7 @@ import bodyParser from 'body-parser'
|
|
|
|
|
|
|
|
|
|
|
|
import productRoutes from './handlers/products'
|
|
|
|
import productRoutes from './handlers/products'
|
|
|
|
import userRoutes from './handlers/users'
|
|
|
|
import userRoutes from './handlers/users'
|
|
|
|
|
|
|
|
import orderRoutes from './handlers/orders'
|
|
|
|
|
|
|
|
|
|
|
|
const app: express.Application = express()
|
|
|
|
const app: express.Application = express()
|
|
|
|
const address: string = "0.0.0.0:3000"
|
|
|
|
const address: string = "0.0.0.0:3000"
|
|
|
@ -16,6 +17,7 @@ app.get('/', function (req: Request, res: Response) {
|
|
|
|
|
|
|
|
|
|
|
|
productRoutes(app)
|
|
|
|
productRoutes(app)
|
|
|
|
userRoutes(app)
|
|
|
|
userRoutes(app)
|
|
|
|
|
|
|
|
orderRoutes(app)
|
|
|
|
|
|
|
|
|
|
|
|
// Start express server
|
|
|
|
// Start express server
|
|
|
|
app.listen(port, function () {
|
|
|
|
app.listen(port, function () {
|
|
|
|