Advertisement
Guest User

Untitled

a guest
Jun 20th, 2019
87
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.79 KB | None | 0 0
  1. const exphbs = require('express-handlebars')
  2. const bodyparser = require('body-parser')
  3. const path = require('path')
  4.  
  5. const app = express();
  6.  
  7. app.get('/', (req, res) => {
  8. app.send('index')
  9. })
  10.  
  11. const PORT = process.env.PORT || 5000;
  12.  
  13. app.listen(PORT, `server started on PORT ${PORT}`)```
  14.  
  15. test
  16.  
  17. /*the error I keep getting is below. I'm feeling like an idiot as I'm unable to even get a basic app to render. I know this question has been asked many times and I'm sorry to post this question again. Any guidance that will yield a solution would be greatly appreciated. */
  18.  
  19. events.js:183
  20. throw er; // Unhandled 'error' event
  21. ^
  22.  
  23. Error: getaddrinfo ENOTFOUND server started on PORT 5000
  24. at errnoException (dns.js:50:10)
  25. at GetAddrInfoReqWrap.onlookup [as oncomplete] (dns.js:92:26)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement