Guest User

Untitled

a guest
Oct 20th, 2017
81
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.40 KB | None | 0 0
  1. app.get('*', function(req, res) {
  2. res.sendFile(path.resolve(__dirname) + '/server/static/index.html');
  3. });
  4.  
  5. // routes
  6. const apiRoutes = require('./server/routes/api');
  7. app.use('/api', apiRoutes);
  8.  
  9. // routes
  10. const apiRoutes = require('./server/routes/api');
  11. app.use('/api', apiRoutes);
  12.  
  13. app.get('*', function(req, res) {
  14. res.sendFile(path.resolve(__dirname) + '/server/static/index.html');
  15. });
Add Comment
Please, Sign In to add comment