Delete http get url (+ angular2 http get)

hey guys.
I want to using angular2’s http. and I make sample code for checking return value.


let url = '' + suburl;

return this.http.get(url).toPromise()
         .then(response => response.json())


these are my code for http get, (I do not really know it works)
and i use url with suburl for my hosting server (i can check server with browser and it works correctly)
but it shows like this (when i user ionic run browser)

now i want adjust my question.

  1. can i delete localhost from url? like
  2. these http.get code is right? how can i use?
  3. additionally, what ‘.then’ works? in other example some people use ‘.map’, I just thought it makes json but didn’t understand.
  4. additionally, .catch like JAVA code’s try, catch??

thanks for reading long question.