Files
cardWorkoutApp/server.js
Will Baumbach 9a170a4953 please work!!
2020-04-21 22:32:37 -04:00

15 lines
423 B
JavaScript

//Install express server
const express = require('express');
const path = require('path');
const app = express();
// Serve only the static files form the dist directory
app.use(express.static('./dist/cardWorkout'));
app.get('/*', function(req,res) {
res.sendFile(path.join(__dirname,'/dist/cardWorkout/index.html'));
});
// Start the app by listening on the default Heroku port
app.listen(process.env.PORT || 8080);