Angular 2 http get not getting

后端 未结 4 1640
心在旅途
心在旅途 2020-11-22 06:22

I new to Angular 2 still learning I am trying to hit a URL with a get call but the get doesn\'t seem to go through even in browser\'s network I cannot find that get URL bein

4条回答
  •  甜味超标
    2020-11-22 06:53

    Note : Make sure to get response from app.js or some other backend services which is not hosted in same angular port we have to keep running both port . So better to use two terminal as I have used VS code terminal to keep running node server (http://localhost:3000/api/get) and used command prompt to keep running Angular server(http://localhost:4200)

提交回复
热议问题